Jump to content

Archived

This topic is now archived and is closed to further replies.

italkonphone

Entering TXT

Recommended Posts

[img src=\"style_emoticons/[#EMO_DIR#]/huh.gif\" style=\"vertical-align:middle\" emoid=\":huh:\" border=\"0\" alt=\"huh.gif\" /] :h

uh: i use dreamweaver to edit php , it is a template, im trying to learn and enter more txt on different linesit just wont let me, the code is as follows if anyone can help most appriciated. thanks peeps.

<?php
/*


*/

define('NAVBAR_TITLE', 'About us');
define('HEADING_TITLE', 'About us');
define('HISTORY_TITLE', 'OUR HISTORY');

define('TEXT_INFORMATION', 'We have a simple philosophy, i talk on phone, you talk on phone everyone talk on phone. Thats what we want to see and to get there we make sure we do it so you enjoy the experiance. Its all about i talk on phone');

the above is shown but i can enter anything else as below


define('TEXT_INFORMATION', 'www.italkonphone.co.uk is a online company, that is independant of all the major networks to you the best deal you deserve.');

define('TEXT_INFORMATION', 'www.italkonphone.co.uk is a VIP service for many clients, what defines a VIP, you do with what you do, what you say and how you say it.');

Share this post


Link to post
Share on other sites
You're reusing the same label in your new defines... try something other than "TEXT_INFORMATION".

Share this post


Link to post
Share on other sites
I would also like to add PHP is a lanuage worth learning outside of dreamweaver. IMO it's far to complex to want to use a WYSIWYG editor.

Your best bet is to use something similar to:

$text_information = 'We have a simple philosophy, i talk on phone, you talk on phone everyone talk on phone. Thats what we want to see and to get there we make sure we do it so you enjoy the experiance. Its all about i talk on phone';

$text_information .= 'www.italkonphone.co.uk is a online company, that is independant of all the major networks to you the best deal you deserve.';

$text_information .= 'www.italkonphone.co.uk is a VIP service for many clients, what defines a VIP, you do with what you do, what you say and how you say it.';

Then simply echo $test_information;

Share this post


Link to post
Share on other sites
There is an amazing number of resources available on the web for PHP beginners. If you really weant to get into dynamic content, it's worth learning to do properly :)

Read up on the php [a href=\"http://www.php.net/echo\" target=\"_blank\"]echo()[/a] command through that link.

Share this post


Link to post
Share on other sites
What exactly are you trying to accomplish? Because if you're really trying to use a lot of text then you should use a database to store it, or something like that. If you don't know what echo is then you need to go find a tutorial most likely. At any rate why not just use straight HTML if you are dead set on writing out all that text into variables? seems like it would take less effort and be just as easy to maintain to write:
<p> blah blah blah </p>
as:
$text = "blah blah blah"
echo $text;

Share this post


Link to post
Share on other sites
i understand echo now but whats happend is its outside the box that i want it in, as above the only statement within the box is define txt_information. is there a way of writing a variable to make it stay within the box ?

Share this post


Link to post
Share on other sites
What box? Are you referring to CSS? Someone above gave you I think the best advice for this problem, just concatenate by using " .= " so instead of overwriting the variable like you were doing above with multiple definitions, you just stick each new string on the end of the old stuff.

$string = "lots of text";
$string .= " even more text";
$string .= " you get the point"
echo $string;
// outputs
// lots of text even more text you get the point

Share this post


Link to post
Share on other sites
I agree with the about about using a WYSISYG editor with PHP. It just shouldn't be done ;)

Even with HTML I would not use dreamweaver for. I used dreamweaver in the past but found it not to my liking and just stuck with notepad (back in the day I used simpletext on my mac).

Anyway I use Crimson editor for my PHP and it allows me to learn how the innerworkings... work.. I guess I just like to look at code. Its the insides of thing that fancinate me, not the 'icing on the cake' ;)

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.