Jump to content

textarea - Displaying database code?


spires

Recommended Posts

Hi

 

I have a text area, that I want to display info pulled from a database.

 

I can get the data to show, But can get each entry of the table

to display on it's own line.

 

Example:

ob1ob2ob3ob4ob5

 

Should be:

ob1

ob2

ob3

ob4

ob5

 

 

CODE:

<textarea id="interest" onfocus="clearInterest()" class="textareacss" style="height:212px;overflow:auto;"><?PHP
		$newInterestSub = Admin_interests_sub::find_by_cat_id($id);
			foreach($newInterestSub as $newInterestSubs){
				echo $newInterestSubs->interest_sub.'\n';
			}
		?></textarea>

 

 

Any help would be great.

Link to comment
https://forums.phpfreaks.com/topic/227221-textarea-displaying-database-code/
Share on other sites

Archived

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

×
×
  • Create New...

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.