close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

MySQLi insert record doesn't show a color picker field in my form

Thread began 8/15/2014 12:06 pm by Jason | Last modified 8/15/2014 12:40 pm by Jason | 1196 views | 4 replies |

Jason

MySQLi insert record doesn't show a color picker field in my form

I'm trying to insert a record into my database using a form that contains a text field and a color picker field. The MySQLi Insert Record doesn't show my color field under Column Bindings tab. I'd prefer to have it take the hex color and only submit the last 6 characters (ignore the #), but if it had to submit all 7 characters that would be fine. But, right now it's not seeing the field at all. The page is attached. Thanks!

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

Jason ByrnesWebAssist

change:
type="color"

to:
type="text"


to do the binding, then change it back after you have done the binding.

Sign in to reply to this post

Jason

Yup that worked! Any way to get it to drop the # at the beginning (So it would insert FFFFFF instead of #FFFFFF into the database?

Sign in to reply to this post

Jason ByrnesWebAssist

add this code at line 1:

<?php
if(isset($_POST['nameofcolorpicker'])) $_POST['nameofcolorpicker'] = str_replace("#","",$_POST['nameofcolorpicker']);
?>



where nameofcolorpicker is the name of the color picker element

Sign in to reply to this post

Jason

PERFECT! Thanks so much for the awesome and timely responses Jason. Have a great weekend!

Sign in to reply to this post

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...