how to add html code to my ezpublish pages.

Author Message

Brian Baxter

Saturday 30 June 2007 4:39:47 pm

Ok, I wanted to basically create a simple page in ez publish, but after reading the manuals, and several forum posts, I was still unable to do so. I want to add a generated payment form from paypal, this is not to be mistaken with the shop, this will do something different from the shop.

The form I am trying to implement is a simple paypal form i have the code it is all html, basically a form tag and thats it. I have been fiddling with .tpl's and this and that, and can't get anything to work with this setup. I am having trouble creating templates and custom pages that I can add my own html to.

I don't feel the doc's or so called faq's are very clear or helpful in the problems that one is having especially attempting to alter the actual look of the site.

Behind every great fortune lies a crime.
http://www.3cwired.com - Web Design/SEO/Repair/Sales/Upgrades
http://www.galants.org - The Home for Galant Enthusiasts
http://www.locatemyip.com - More than just free IP displays

Andreas Kaiser

Sunday 01 July 2007 3:34:53 pm

Do you want to paste the html code inside a template file (tpl) or inside the web editor? Also do you want to have this paypal form in all the pages of your sites or just in some?

eZ Partner in Madrid (Spain)
Web: http://www.atela.net/

Brian Baxter

Sunday 01 July 2007 10:16:53 pm

it doesnt matter, as long as i can add the generated paypal code, it could be in the web editor or a tpl file, whichever works, and preferably the easier solution :)

here is the sample code:

<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="image" src="https://www.paypal.com/en_US/i/btn/x-click-but6.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!">
<img alt="" border="0" src="https://www.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
<input type="hidden" name="encrypted" value="mysecretcode :)">
</form>

Yes all I am trying to do is add the paypal forms code which is basic html.

it is just a simple payment button, where my clients can go to pay specific invoices, that may be $1, $10 or $100, or even $100.10 so this is why this is needed as it is generic, and will work well. I currently had to make a temporary solution to assist paying clients now, but I need to have it "included" within the site.

BTW, I am using 3.9.2

Behind every great fortune lies a crime.
http://www.3cwired.com - Web Design/SEO/Repair/Sales/Upgrades
http://www.galants.org - The Home for Galant Enthusiasts
http://www.locatemyip.com - More than just free IP displays

Heath

Sunday 01 July 2007 10:41:32 pm

Why not use a 'custom tag' ?

http://ez.no/doc/content/advancedsearch?SearchText=custom+tag&SearchSectionID=18
http://ez.no/doc/ez_publish/technical_manual/3_9/reference/datatypes/xml_block/custom_tags
http://ezpedia.org/wiki/en/ez/solution_inserting_inline_client_script_into_content_using_a_custom_tag
http://ezpedia.org/wiki/en/ez/custom_tag

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

Andreas Kaiser

Monday 02 July 2007 3:10:51 am

Like Heath said, for the web editor using custom tags would be the best. For a tpl file you only should paste the code... and it should work...

I don't see any curly braces in your code, so there should be no problem... anyway you can test with:

{literal}
your code
{/literal}

I have to admit, I'm not very familiar with the new webmin extension and how the override of templates is done in this case... But this should help: http://ezpedia.org/wiki/en/ez/overriding_the_ez_web_interface_ezwebin_with_custom_designs

eZ Partner in Madrid (Spain)
Web: http://www.atela.net/

Andreas Kaiser

Monday 02 July 2007 3:12:26 am

Forgot to ask, if you have deleted cache after adding the code to the tpl files?

eZ Partner in Madrid (Spain)
Web: http://www.atela.net/

Brian Baxter

Monday 02 July 2007 6:15:42 am

Thanks, after playing with it, and understanding, and then noticing that I needed to enable the custom tag in admin mode as well, I got it working. Thanks for your prompt reply. Hopefully that will suit all my needs now that I know how to do it.

Behind every great fortune lies a crime.
http://www.3cwired.com - Web Design/SEO/Repair/Sales/Upgrades
http://www.galants.org - The Home for Galant Enthusiasts
http://www.locatemyip.com - More than just free IP displays

Antone Antonia

Sunday 08 July 2007 8:07:45 pm

---spam---

Betsy Gamrat

Thursday 12 July 2007 8:52:38 am

One other option is to create a custom class with a text block attribute. Enter the HTML in the text block and display it with {$node.data_map.text_block.content}.

This allows you to manage the HTML as content.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 14:52:03
Script start
Timing: Jan 18 2025 14:52:03
Module start 'layout'
Timing: Jan 18 2025 14:52:03
Module start 'content'
Timing: Jan 18 2025 14:52:03
Module end 'content'
Timing: Jan 18 2025 14:52:03
Script end

Main resources:

Total runtime0.0189 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0063 588.0469152.6406
Module start 'layout' 0.00630.0039 740.687539.4766
Module start 'content' 0.01020.0069 780.1641101.4922
Module end 'content' 0.01710.0018 881.656346.3047
Script end 0.0189  927.9609 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002513.2109140.0002
Check MTime0.00105.3721140.0001
Mysql Total
Database connection0.00084.432610.0008
Mysqli_queries0.003317.618430.0011
Looping result0.00000.137510.0000
Template Total0.00147.510.0014
Template load0.00083.982410.0008
Template processing0.00073.512110.0007
Override
Cache load0.00052.655810.0005
General
dbfile0.00136.626980.0002
String conversion0.00000.054240.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs