Skip to main content
Participating Frequently
January 15, 2011
Answered

META TAG DESCRIPTION TO STRIP TAG

  • January 15, 2011
  • 1 reply
  • 965 views

Hello to all the Adobe community, today is the first time I'm posting a question in the forum.

I am a developer new to PHP, and I use Dreamweaver every day.

I apologize because I do not speak English, I type in google translator is no doubt that you can help me

I have a web site hosted www.gotejar.org, it is a dynamic site using technology PHP / MYSQL.

I have a database and a table called news within this table I have a field called description.

I'm using Adobe Dreamweaver to make the connection to the database and also make the recordset

Now comes the question?

I would like to know how to put this description within the TAG field
<meta name="description" content="" /> without html tags, because when I do a record on the registration form of news this field is linked with tinyMCE

For example:

<Meta name = "description" content = "<? Php echo $ row_rs_tag_description ['description'];?>" />

I know this is possible with the function of PHP Strip Tags.
How to do this, esquero make no mistake, I apologize again because I do not speak English.

If anyone can help me can send me an email.

E-mail: rodrigo.mct @ gmail.com

Rodrigo Vieira da Silva Eufrasio
Brazil - Osasco - SP
+55 11 8183-9488
This topic has been closed for replies.
Correct answer David_Powers

Rodrigo_2009 wrote:

I would like to know how to put this description within the TAG field
<meta name="description" content="" /> without html tags,

You use strip_tags() and htmlentities() like this:

<meta name="description" content="

<?php echo htmlentities(strip_tags($row_rs_tag_description ['description']), ENT_COMPAT, 'UTF-8');?>" />

1 reply

David_Powers
David_PowersCorrect answer
Inspiring
January 15, 2011

Rodrigo_2009 wrote:

I would like to know how to put this description within the TAG field
<meta name="description" content="" /> without html tags,

You use strip_tags() and htmlentities() like this:

<meta name="description" content="

<?php echo htmlentities(strip_tags($row_rs_tag_description ['description']), ENT_COMPAT, 'UTF-8');?>" />

Participating Frequently
January 15, 2011

Thank you David, this helped me a lot, I'll be posting more questions in this forum and taking questions from all you need at my fingertips. God bless you abundantly.

Listen
Read phonetically

Dictionary - View detailed dictionary

  1. interjection
    1. Thank you very much