needhelpplease Posted July 6, 2013 Posted July 6, 2013 Hello, i need to convert word/text into php for my shops text pages (conditions, information, shipping & returns, etc.) how to do it please ? My actual sample: "condiitons.php": <?php /* $Id$ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2002 osCommerce Released under the GNU General Public License */ define('NAVBAR_TITLE', 'Conditions of Use'); define('HEADING_TITLE', 'Conditions of Use'); define('TEXT_INFORMATION', 'bla bla bla bla'); ?> Now i need to insert this text into it and substitute the "bla bla bla bla" text information: § 1 Information By using this website you accept and agree to be bound by these Shopping Terms and Conditions, the Privacy Statement and such other policies as we notify you of from time to time, which together constitute the entire agreement between us. Nothing in these Shopping Terms and Conditions affects your statutory rights, either as a consumer or otherwise. These Shopping Terms and conditions apply to all orders which you, the customer, place using our website. Please read them carefully before placing your order and print a copy for future reference. § 2 Your Account You may register with us when purchasing items using this Website. You are responsible for maintaining the confidentiality of your account username and password and for preventing unauthorized access to your account. You accept responsibility for all activities that occur under your account or password, so please .............. HOW to insert it ? WHAT needs to be done ? Please need urgent help. Regards
multimixer Posted July 6, 2013 Posted July 6, 2013 Something like this define('TEXT_INFORMATION', ' <h2>§ 1 Information</h2> <p>By using this website you accept and agree to be bound by these Shopping Terms and Conditions, the Privacy Statement and such other policies as we notify you of from time to time, which together constitute the entire agreement between us. Nothing in these Shopping Terms and Conditions affects your statutory rights, either as a consumer or otherwise. These Shopping Terms and conditions apply to all orders which you, the customer, place using our website. Please read them carefully before placing your order and print a copy for future reference.</p> <h2>§ 2 Your Account</h2> <p>You may register with us when purchasing items using this Website. You are responsible for maintaining the confidentiality of your account username and password and for preventing unauthorized access to your account. You accept responsibility for all activities that occur under your account or password, so please</p> '); My community profile | Template system for osCommerce - New: Responsive | Feedback channel
needhelpplease Posted July 6, 2013 Author Posted July 6, 2013 mate, thanks very much. any idea how to make it left and right aligned ? regards
multimixer Posted July 6, 2013 Posted July 6, 2013 http://www.w3schools.com/css/ My community profile | Template system for osCommerce - New: Responsive | Feedback channel
MrPhil Posted July 6, 2013 Posted July 6, 2013 A couple of things to keep in mind: 1. If you have an apostrophe (single quote) in the middle of your text (e.g., "Please don't feed the sharks"), you need to escape it: "Please don\'t feed the sharks". 2. The use of non-ASCII punctuation can be a problem if you don't edit the file in the same character encoding as it will be displayed in. It's usually safer to use HTML entities (e.g., § or § gives you the "section sign").
Chris H Posted July 6, 2013 Posted July 6, 2013 Html tags can be freely included, as multimixer suggests. <html> <head></head> <body> <?php define('TEXT_INFORMATION', ' <div style="width:300; text-align:justify"> <h2>§ 1 Information</h2> <p>By using this website you accept and agree to be bound by these Shopping Terms and Conditions, the Privacy Statement and such other policies as we notify you of from time to time, which together constitute the entire agreement between us. Nothing in these Shopping Terms and Conditions affects your statutory rights, either as a consumer or otherwise. These Shopping Terms and conditions apply to all orders which you, the customer, place using our website. Please read them carefully before placing your order and print a copy for future reference.</p> <h2>§ 2 Your Account</h2> <p>You may register with us when purchasing items using this Website. You are responsible for maintaining the confidentiality of your account username and password and for preventing unauthorized access to your account. You accept responsibility for all activities that occur under your account or password, so please</p> </div> '); echo(TEXT_INFORMATION); ?> </body> </html>
♥14steve14 Posted July 7, 2013 Posted July 7, 2013 Hello, i need to convert word/text into php for my shops text pages (conditions, information, shipping & returns, etc.) how to do it please ? Just to make a small correction. You are converting text to html not php. If you are unsure of html code try searching online for a free html wysiwyg editor. There are quite a few available. There are also some that can be added to your store in the addons area. REMEMBER BACKUP, BACKUP AND BACKUP
MrPhil Posted July 7, 2013 Posted July 7, 2013 Well, it's a little of both... the use of HTML for anything other than plain text, and then how to put that into PHP (the only thing to worry about is escaping single quotes/apostrophes). I still strongly suggest using HTML entities rather than hard coding (binary) non-ASCII characters such as the section symbol.
myquestionone Posted July 10, 2013 Posted July 10, 2013 thx very much. excellent help. regards Signature: Apologies for my bad english - i am not a native speaker. Please forgive me. Thx and Cheers.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.