latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Specific post page button adds whitespace

Home Forums Community Forum Specific post page button adds whitespace

This topic contains 24 replies, has 11 voices. Last updated by  Anthony Sielten 3 years, 4 months ago.

Topic Author Topic
Posted: Saturday Jun 23rd, 2012 at 10:31 am #17248

I have created a page that should be a pay to access. I can get the code working fine, however when inserting the paypal button via either the shortcode or the full code, it also inserts 50 lines of white space. I have tried disabling all plugins and reverting to the standard theme, but have the same issue.

This puts the button way down the page. I have also put the button on a blank page of it’s own and the same thing happens.

The page is here http://www.themitchelli.com/virtual-outfit-assessment/buy-voa/ The shortcode was unmodified. Any assistance would be appreciated.

edit: I have moved the button to the top of the page to further demonstrate the issue.

Steve

List Of Topic Replies

Viewing 24 replies - 1 through 24 (of 24 total)
Author Replies
Author Replies
Posted: Saturday Jun 23rd, 2012 at 8:17 pm #17262
RJ Cantu
Username: rjcan2

It seems the Worpress Update is causing this issue. I’ve used a default theme and posted the buttons on a blank page and sure enough the gap of white space still shows up. This has a huge effect on the membership buy now pages. Hopefully S2 Member will have an update soon and I’ll hang-tight.

PS- I think S-2 members is the BEST memberships options out on the market. great job you guys :) !

http://www.magicspacextreme.com

  • This reply was modified 4 years, 6 months ago by  RJ Cantu.
Posted: Monday Jun 25th, 2012 at 9:46 am #17365
Eduan
Username: Eduan
Moderator

Hello guys,

I will notify Jason of this, in case this is an s2member bug. :)

Posted: Tuesday Jun 26th, 2012 at 4:01 pm #17570
Scott Ewalt
Username: eroq77

I’m having the same problem. Chrome browser “inspect element” shows the form that the paypal button is placed has a height of 709px. As an experiment, I used the long code for the paypal button and removed all the hidden input fields (I know this makes the button not work), but the result fixed the white space problem.

So I’m thinking there must be a CSS workaround for hidden input fields, I’ll let you know if I find anything.

  • This reply was modified 4 years, 6 months ago by  Scott Ewalt.
Posted: Tuesday Jun 26th, 2012 at 5:46 pm #17588
Scott Ewalt
Username: eroq77

I found a solution!!!

I used the long code for the paypal button, and I wrapped a div around all the hidden input fields and added the needed style code to get rid of the white space.

At the beginning of the form, the next line after the opening form tag, just add the opening div tag:

<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
 <div style="display: none;">
 <input type="hidden" name="business" value="youremail@email.com" />
 <input type="hidden" name="cmd" value="_xclick" />
  ....
 

Then at the end of the form, right before the input “image” field for the paypal button, add the closing div tag:

....
<!-- Displays The PayPal® Image Button -->
</div>
<input type="image" src="https://www.paypal.com/en_US/i/btn/btn_xpressCheckout.gif" style="width:auto; height:auto; border:0;" alt="PayPal®" />
</form>
  • This reply was modified 4 years, 6 months ago by  Scott Ewalt.
  • This reply was modified 4 years, 6 months ago by  Scott Ewalt.
Posted: Tuesday Jun 26th, 2012 at 8:31 pm #17595

That worked perfectly, thank you.

Posted: Tuesday Jun 26th, 2012 at 9:20 pm #17598
RJ Cantu
Username: rjcan2

Seems to have taken care of the white space…GREAT JOB! Thanks :)

http://www.magicspacextreme.com

  • This reply was modified 4 years, 6 months ago by  RJ Cantu.
  • This reply was modified 4 years, 6 months ago by  RJ Cantu.
Posted: Tuesday Jun 26th, 2012 at 9:50 pm #17601
RJ Cantu
Username: rjcan2

Only problem I’m seeing…(if I’m putting in your coding properly). When you click on the paypal button and it takes you to YOUR ORDER SUMMARY look at the options: it adds a weird S2 member code. Just hope this doesn’t affect the auto link it sends to the customer. Thanks again :)

http://www.magicspacextreme.com

Posted: Tuesday Jun 26th, 2012 at 10:39 pm #17602
Scott Ewalt
Username: eroq77

Oh I see that weird code too.

Try regenerating a new button code, use the long code, and add the fix from my solution.

It worked for me, I’m thinking they changed something in the papal button generator since the time I originally made the button.

Posted: Tuesday Jun 26th, 2012 at 10:41 pm #17603
RJ Cantu
Username: rjcan2

Yeah…seems to be doing the same in a new generated long code too. SOOOOO CLOSE lol!

http://www.magicspacextreme.com

  • This reply was modified 4 years, 6 months ago by  RJ Cantu.
Posted: Tuesday Jun 26th, 2012 at 10:48 pm #17606
Scott Ewalt
Username: eroq77

If you have used the new generated code with fix, try closing your browser and open it again to get a good refresh of your website. Maybe that will do it? …Hopefully

Posted: Tuesday Jun 26th, 2012 at 10:50 pm #17607
Scott Ewalt
Username: eroq77

Also, are you using the latest update of s2Member? They did launch an update recently.

Posted: Tuesday Jun 26th, 2012 at 10:55 pm #17608
RJ Cantu
Username: rjcan2

Let me try clearing cookies…that might be the problem. Are you getting a clean “Your Order Summary” page on paypal? Or do you get the weird S2 member code on yours?

Posted: Tuesday Jun 26th, 2012 at 10:57 pm #17609
Scott Ewalt
Username: eroq77

I was getting the weird s2member code in paypal’s summary page, but not anymore since generating a new button.

Posted: Wednesday Jun 27th, 2012 at 2:34 pm #17678
Staff Member

Thanks for the heads up on this thread.

I just wanted everyone to know that we did see this report, and it has been tested under WP 3.4, with the default theme. I was unable to reproduce the issue reported here. I suspect the underlying cause might have been filters applied by other plugins and/or a theme (perhaps another plugin in certain installations that needed an update for compatibility with WP 3.4). For example, something like the RAW HTML plugin, or another plugin that affects WP output filters. It would be a good idea to update those plugins too.

If the problem continues for anyone, please update us here, and we’ll dig deeper.

Posted: Thursday Jun 28th, 2012 at 3:52 am #17728

I have the same issue (WP 3.4.1). I dont have any special plugin. I tried it with Canvas (woo theme) and Genesis theme and got the same whitespaces.

Posted: Thursday Jun 28th, 2012 at 12:08 pm #17771
Scott Ewalt
Username: eroq77

I made a correction to the solution, the div tag should have a style set to display none, check my corrected post above.

Posted: Friday Jun 29th, 2012 at 3:50 pm #17882

The CookieMonster plugin produced this error in my case. I turned off all plugins and reactivate them 1 by 1.

Posted: Monday Jul 2nd, 2012 at 2:50 am #18062
Scott Ewalt
Username: eroq77

In my case, it was the theme that is causing the error, in which case I’ve spent too much time customizing and can’t/won’t switch to a compatible theme.

I must admit that my solution has encountered errors on the paypal side because I was using the long form code when generating a paypal button.

So I’ve modified and tested a new solution, that works perfectly!!! For anybody out there that still needs this little solution, try this…

I now use the shortcode and copy it, go back to the post/page you want, use the HTML editor and paste your shortcode, then type the following code before the shortcode:

<div style="margin-top: -640px;">

and right after the shortcode close it with this code:

</div>

Full example:

<div style="margin-top: -640px;">
[s2Member-PayPal-Button level="1" ccaps="" desc="yourdescription" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="yourwebsite.com" ta="0" tp="0" tt="D" ra="0.01" rp="1" rt="L" rr="BN" rrt="" rra="1" image="default" output="button" /]
</div>

You might have to experiment with the margin-top: -640px. Play around with that negative number until it looks right for your website.

Posted: Wednesday Jul 4th, 2012 at 12:02 pm #18307

many thanks for those who solved this problem !! great job

Posted: Saturday Jul 14th, 2012 at 6:11 am #19231

I would hope that s2member would do something to fix this issue. Thank you for code to take out the white space.

Posted: Saturday Sep 22nd, 2012 at 2:04 pm #26127
Peter R
Username: PeterRK

If you are having this issue it is probably a plugin or theme file that is calling the wpautop formatting function. Wpautop will add unwanted linebreaks in some situations. It shouldn’t be a problem with just a vanilla install of s2member and wordpress, but other plugins/themes could be modifying the formatting in ways that create ugly output (extra line spaces etc).

I wrote a troubleshooting guide here
http://www.peterrknight.com/troubleshooting-auto-formatting-issues-in-wordpress/

with one solution that doesn’t involve deactivating a plugin/theme here:

http://www.peterrknight.com/troubleshooting-auto-formatting-issues-in-wordpress/#correctivefilter

Posted: Thursday Oct 11th, 2012 at 6:03 pm #28170

Peter R – great fix without deactivating any plug-ins or themes!

Posted: Monday Feb 18th, 2013 at 3:28 pm #42321

Getting the same white space error as well, I used the negative top margin div as a fix but since the latest update the only way my paypal button will work is if I wrap [raw] tags around it – which then breaks the container div.

Currently looking into the theme to see if there is a way to fix the added
tags after each hidden form element. Not quite sure what to do.

Posted: Monday Aug 12th, 2013 at 9:31 am #55575

I am still having problems with this. I guess we do have the pro version… Mine appeared after the upgrade to WordPress 3.6
http://www.s2member.com/forums/topic/new-extra-space-before-paypal-button/

Viewing 24 replies - 1 through 24 (of 24 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.