Adding a Paypal Donate button to header 3.1 Prosilver SE

Get help with installation and running phpBB 3.1.x here. Please do not post bug reports, feature requests, or extension related questions here.
Scam Warning
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTE: phpBB 3.1.x is at its End of Life stage and support will NOT be provided after July 1st, 2018.
mtridersclb
Registered User
Posts: 86
Joined: Wed Oct 01, 2008 7:15 pm

Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by mtridersclb »

Hi Chaps

re: www.mtridersclub.co.uk

Really pleased with the look so far thanks to your help. Now I want to add a Donate button to the header or somewhere obvious. Here is the Html from Paypal:

<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="HQ2J6KJTDTBEG">
<input type="image" src="https://www.paypal.com/en_GB/i/btn/btn_donate_LG.gif" border="0" name="submit" alt="PayPal โ€“ The safer, easier way to pay online.">
<img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1">
</form>

I know phpbb isnt html but can I use that or how would I do this please/

Thanks very much

Simon
JacobOre
Registered User
Posts: 3
Joined: Sat Jan 30, 2016 10:55 am

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by JacobOre »

You'd have to edit the style's template you're using.
User avatar
Lumpy Burgertushie
Registered User
Posts: 69228
Joined: Mon May 02, 2005 3:11 am

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by Lumpy Burgertushie »

yes, phpbb uses html just like any other webpage. the difference is in the other things that are used to collect the database info to add things to the pages.

anyway, using your ftp, download the overall_header.html file for your prosilver style.

using ONLY a good text editor, open the file. you can add your paypal htmlm wherever you want your button to show up. save the file, upload it back and then go to the admin panel and purge the cache and then refresh your browser to see the new button.


robert
Premium phpBB 3.3 Styles by PlanetStyles.net

I am pleased to announce that I have completed the first item on my bucket list. I have the bucket.
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by 3Di »

Image


using with BBcodes

Code: Select all

[url=https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=HQ2J6KJTDTBEG][img]https://www.paypal.com/en_GB/i/btn/btn_donate_LG.gif[/img][/url]
๐Ÿ†“ Free support for our extensions also provided here: phpBB Studio
๐Ÿš€ Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity ยบ PhpStorm's proud user ยบ Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
Lumpy Burgertushie
Registered User
Posts: 69228
Joined: Mon May 02, 2005 3:11 am

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by Lumpy Burgertushie »

yes, but bbcode only works in a post, not in the normal html as the OP requires.


robert
Premium phpBB 3.3 Styles by PlanetStyles.net

I am pleased to announce that I have completed the first item on my bucket list. I have the bucket.
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by 3Di »

Ditto, mine is a knowledge-sharing, so to say. For posterity and for all of them wanted to use it as an alternative.
So, right or wrong I am on topic I believe. And yes, I am used to read the whole topics before to write something.
Regards. :)
๐Ÿ†“ Free support for our extensions also provided here: phpBB Studio
๐Ÿš€ Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity ยบ PhpStorm's proud user ยบ Extensions, Scripts, MOD porting, Update/Upgrades
mtridersclb
Registered User
Posts: 86
Joined: Wed Oct 01, 2008 7:15 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by mtridersclb »

Thank you very much for your replies, I have tried pasting it into a couple of different places but cannot work out how to control its position. I am slowly seeing that differen <div> areas are relevant but exactly where to slot it in I cannot work out.
Ideally I would like it on the grey line, centered between the 'Board Index' and the Search box.

www.mtridersclub.co.uk

Thank you very much
User avatar
janus_zonstraal
Registered User
Posts: 6614
Joined: Sat Aug 30, 2014 1:30 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by janus_zonstraal »

Try behind

Code: Select all

<!-- END navlinks -->
in the navbar_header.html from your style (+/- line 105)
Sorry! My English is bat ;) !!!
mtridersclb
Registered User
Posts: 86
Joined: Wed Oct 01, 2008 7:15 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by mtridersclb »

Ahh! Thats the slot thank you, now how to center it? Ive tried adding

align="middle"

but that didnt work :-)
User avatar
janus_zonstraal
Registered User
Posts: 6614
Joined: Sat Aug 30, 2014 1:30 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by janus_zonstraal »

I think you have to place it a little bit further in the code, now yours links are broken.
How to align it it I don't know, just try with "center" or so??
Sorry! My English is bat ;) !!!
User avatar
Lumpy Burgertushie
Registered User
Posts: 69228
Joined: Mon May 02, 2005 3:11 am

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by Lumpy Burgertushie »

the problem with putting it there is that the breadcrumbs will move it across the space until there is not enough space left for it and strange things will happen etc.

best put it in the header section somewhere or on a line by itself under that grey section or at the bottom of the page etc.


robert
Premium phpBB 3.3 Styles by PlanetStyles.net

I am pleased to announce that I have completed the first item on my bucket list. I have the bucket.
User avatar
Volksdevil
Registered User
Posts: 2415
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by Volksdevil »

Something like this may look better? Just a quick edit, placed either after the navbar, or in the top of the forumlist_body.html file so it only appears on the index page.

Code: Select all

<div class="navbar" style="text-align:center;margin-bottom:.5em;">
If you can spare a little change you can donate to {SITENAME}. Any donation, no matter how small always helps.<br />
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top" style="margin-top:.5em;">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="HQ2J6KJTDTBEG">
<input type="image" src="https://www.paypal.com/en_GB/i/btn/btn_donate_LG.gif" border="0" name="submit" alt="PayPal โ€“ The safer, easier way to pay online.">
<img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1">
</form>
</div>
Note that doing this means any updates to the site will mean you will lose the change unless you carry out the edit again.
My phpBB Extensions
Finally found great Website Hosting from :arrow: KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Twitch | My Volkswagen Corrado G60
mtridersclb
Registered User
Posts: 86
Joined: Wed Oct 01, 2008 7:15 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by mtridersclb »

Robert thank you:
Yes, the breadcrumbs did push it over, in fact in some deeper forums the Paypal button was duplicated or even triplicated.

I have now put it back into overall_header. I am trying ot centre it, I have managed it in the editor by increasing the cell padding in forms.css - is that the best way to do it? Also it touched the line below.

Ah ok, Volksdevil I have just read your post, thank you - Im happy for it to appear in all forums so where you say "Just a quick edit, placed either after the navbar," is that still in overall-header?
User avatar
Volksdevil
Registered User
Posts: 2415
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by Volksdevil »

Yep, I'm not familiar with the style you use, in overall_header.html do you have an:
<!-- EVENT overall_header_page_body_before -->?
If so, you could place it directly before or after that.

Or if you have an:
<!-- EVENT overall_header_content_before -->, same deal. Just see which works best for you.
My phpBB Extensions
Finally found great Website Hosting from :arrow: KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Twitch | My Volkswagen Corrado G60
mtridersclb
Registered User
Posts: 86
Joined: Wed Oct 01, 2008 7:15 pm

Re: Adding a Paypal Donate button to header 3.1 Prosilver SE

Post by mtridersclb »

Thank you, Ill have a look.

I have broken something - now when we use the Search box, we go directly to the Paypal page!!

Return to โ€œ[3.1.x] Support Forumโ€