The PHP Group PHP Logo
Posted on Feb 26, 2009

PHP issues with ''''... Please help!!!

Many php scripts uses the php clauses as folows:

''
Welcome to our site,.
We hope you like your stay!!!''

They add simple script parts like ''''!
My php parser doesn't parse this parts...
How can I fix this???
The php parser parses '''' fine but
not ''
How can I fix this???

I'm currently running windows XP and using wampserver to run php, apache and msql on my pc.

Thankyou very much!!!

  • Master Lucka Feb 27, 2009

    thankyou very much. in the php.ini there is a setting:

    ; Allow the tags are recognized.
    ; NOTE: Using short tags should be avoided when developing applications or
    ; libraries that are meant for redistribution, or deployment on PHP
    ; servers which are not under your control, because short tags may not
    ; be supported on the target server. For portable, redistributable code,
    ; be sure not to use short tags.
    short_open_tag = On

    Lucka


  • Anonymous May 11, 2010

    I think there is a setting within php.ini but its been awhile since I've looked through there.

×

1 Answer

Anonymous

Level 1:

An expert who has achieved level 1.

Hot-Shot:

An expert who has answered 20 questions.

Corporal:

An expert that hasĀ over 10 points.

Mayor:

An expert whose answer gotĀ voted for 2 times.

  • Contributor 23 Answers
  • Posted on Mar 06, 2009
Anonymous
Contributor
Level 1:

An expert who has achieved level 1.

Hot-Shot:

An expert who has answered 20 questions.

Corporal:

An expert that hasĀ over 10 points.

Mayor:

An expert whose answer gotĀ voted for 2 times.

Joined: Mar 06, 2009
Answers
23
Questions
0
Helped
10808
Points
21

Hello.

If you want PHP to use quotation marks you have to seperate them from the ones that start the expression by a backslash(\).

Here are two examples:
WRONG: echo "A "QUOTE" AND SOME TEXT";
RIGHT: echo "A \"QUOTE\" AND SOME TEXT";

or

WRONG: echo 'A 'QUOTE' AND SOME TEXT';
RIGHT: echo 'A \'QUOTE\' AND SOME TEXT';

I hope this helps.

Kind Regards,
Wilhelm@X-ex.info

Add Your Answer

×

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

555 views

Ask a Question

Usually answered in minutes!

Top The PHP Group Computers & Internet Experts

Rob Hill
Rob Hill

Level 3 Expert

1483 Answers

Nikole Brown
Nikole Brown

Level 2 Expert

124 Answers

Syed Bilal
Syed Bilal

Level 3 Expert

252 Answers

Are you a The PHP Group Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...