Forums / Setup & design / how to add html code to my ezpublish pages.

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.

eZ debug

Timing: Jan 18 2025 10:36:23
Script start
Timing: Jan 18 2025 10:36:23
Module start 'content'
Timing: Jan 18 2025 10:36:23
Module end 'content'
Timing: Jan 18 2025 10:36:24
Script end

Main resources:

Total runtime1.0481 sec
Peak memory usage4,096.0000 KB
Database Queries218

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0059 588.9609180.8125
Module start 'content' 0.00590.8506 769.7734728.6797
Module end 'content' 0.85650.1915 1,498.4531344.4297
Script end 1.0480  1,842.8828 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00460.4367210.0002
Check MTime0.00150.1469210.0001
Mysql Total
Database connection0.00080.079110.0008
Mysqli_queries0.940989.77812180.0043
Looping result0.00330.31272160.0000
Template Total1.014096.820.5070
Template load0.00250.237620.0012
Template processing1.011596.512320.5058
Template load and register function0.00010.012810.0001
states
state_id_array0.00110.104010.0011
state_identifier_array0.00230.217420.0011
Override
Cache load0.00190.1793400.0000
Sytem overhead
Fetch class attribute can translate value0.00150.145260.0003
Fetch class attribute name0.00240.2291120.0002
XML
Image XML parsing0.00240.225660.0004
class_abstraction
Instantiating content class attribute0.00000.0029140.0000
General
dbfile0.00550.5280400.0001
String conversion0.00000.000530.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
9content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
12content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 31
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs