close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

my database displays html code on webpages

Thread began 1/10/2020 8:28 am by Jedi | Last modified 1/10/2020 7:00 pm by Ray Borduin | 1232 views | 10 replies |

Jedi

my database displays html code on webpages

I see the html in myPhpAdmin when I do upates to database fields. This also displays html code on my live pages. Any ideas?

Attached Files
contents_update.php
Sign in to reply to this post

Ray BorduinWebAssist

Our MySQLi library has automatic Cross Site Scripting protection. You have to manually disable it in the code when you want it to render html code.

Anywhere you want html code to be rendered you have to update code that looks like this:
$RecordsetName->getColumnVal("ColumnName")

to this:
$RecordsetName->getColumnVal("ColumnName",false)

Adding the false argument at the end tells it to disable the Cross Site Scripting protection and allow html to be rendered on the page.

Sign in to reply to this post
Did this help? Tips are appreciated...

Jedi

Thanks Ray, I did look at the post prior to posting this and I believe that I have corrected any mistakes and I still get html coding in my database. It doesn't show on the editor page as I do it but it does show up in the results page and then on the website live page as html coded around the text.

Sign in to reply to this post

Ray BorduinWebAssist

Please attach a copy of the page and include the line number where the wrong code is displayed and I'll take a look.

Sign in to reply to this post
Did this help? Tips are appreciated...

Jedi

I could only see where to correct the code was on line 64. I am attaching the page and the look on the results page too.

Attached Files
contents_update.php
Sign in to reply to this post

Ray BorduinWebAssist

You sent a copy of the update page and a screen shot of the results page... can I see a copy of the results page. I'd like to work on one page or the other.

Does the content in the html edtior not look correct either? I'd like to get a copy of the page that needs to be fixed... that appears to be the results page based on the attached screenshot.

Sign in to reply to this post
Did this help? Tips are appreciated...

Jedi

It shows up as code on the update page when I go back to it as well. Copies attached

Attached Files
contents_results.php
contents_update.php
Sign in to reply to this post

Ray BorduinWebAssist

On the results page line 275, this code:
<?php echo($WADAcontents->getColumnVal("contContent")); ?>

should be:
<?php echo($WADAcontents->getColumnVal("contContent",false)); ?>

If that still doesn't work, you may have an older version of rsobj.php. I'll attach the latest version, but you might want to also reinstall DataBridge so you have the latest version in future applications.

Attached Files
rsobj.php
Sign in to reply to this post
Did this help? Tips are appreciated...

Jedi

Thanks Ray, That made it look good on those 2 pages. I still have a problem though of it seems to go into the database table with code that shows as code on the live page.
http://www.jaxgator.com/details.php?contID=3

Sign in to reply to this post

Ray BorduinWebAssist

You have to add the false argument to the getColumnVal() call on any page where you want the html to render instead of display as text.

Sign in to reply to this post
Did this help? Tips are appreciated...
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...