close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Generate connections for additional domains dynamically - Dynamic MySql Connection

Thread began 8/01/2012 12:14 pm by jason363662 | Last modified 8/01/2012 12:48 pm by jason363662 | 616 views | 3 replies |

jason363662

Generate connections for additional domains dynamically - Dynamic MySql Connection

I'm clearly not understanding the fundamentals of Dynamic MySQL Connections. I have it set up for a site and it is working correctly to connect on Localhost and my live server when I put the live server host name in the "For Domains" field. I host multiple domains and would like all of them to be able to use the connection. I get this to happen correctly if I manually enter them into the "For Domains" field seperated by commas - However, I have a table that lists all of my domains within my database and I would like to populate the "For Domains" dynamically from this table.

What I don't understand is, do I create a recordset for this table of domains in the connections page? This doesn't make sense to me because what connection would I use?

I know I am missing something simple here - I just can't figure it out - thanks for any help.

Sign in to reply to this post

Jason ByrnesWebAssist

this is circular logic.

the connection file creates the connection to the database.

you can use information from the database to populate the file that will make the connection to the database.

Dynamic connections allows you to specify a different mysql server connection for each domain, but that information needs to be statically entered, it cannot come from the database.

the idea of Dynamic Connections is to dynamically change the connection that will be used based on the Domain in the address bar.

Sign in to reply to this post

jason363662

[SOLVED - SEE REPLY]

That makes sense.

Here's what I am trying to accomplish: I have a page that needs to be dynamically populated based on domain. Though it's the same page, and uses the same connection, I need to create a recordset based on domain. I already have code that works to accomplish this just fine - the problem is that Dynamic MYSQL Connection doesn't work if the domain isn't entered in the "For Domains" field.

Would there be a way to put a wildcard in that field so that it accepts any domain?

Or do you have another suggestion to accomplish what I am trying to do here?

Sign in to reply to this post

jason363662

Solved

Got it - I used the server variable HTTP_HOST under the lightning bolt and it is now working properly.

Thank you for your help - you guys give awesome customer support.

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