swagpixels Posted February 1, 2013 Share Posted February 1, 2013 <?php CLASS DB_MYSQL { var $Host; swagpixels.com, var $Database; swagpixe_swoopo, var $User; swagpixe_swoopad, var $Password; ******, var $Link_ID = 0; // Result of mysql_connect(). var $Query_ID = 0; // Result of most recent mySQL_query(). var $record = array(); // Current mysql_fetch_array()-result. var $Row; // Current row number. var $Errno = 0; // Error state of query... var $Error = ""; var $DDtable="_dt"; // Data Dictionary Tables var $DDfield="_df"; // Data Dictionary Fields Parse error: syntax error, unexpected T_STRING, expecting T_FUNCTION in /home/swagpixe/public_html/.htinc/_mysql.inc on line 6 Line 6 is the host line.... whats wrong? All the parenthesis are there and everything. Link to comment https://forums.phpfreaks.com/topic/273917-need-help-error-in-php-coding-help-please/ Share on other sites More sharing options...
jcbones Posted February 1, 2013 Share Posted February 1, 2013 Where is the difference between this line: var $Link_ID = 0; and this one: var $Host; swagpixels.com, Also, note that this is a very old class, and should be dropped for the mysqli extension, or the PDO class. Link to comment https://forums.phpfreaks.com/topic/273917-need-help-error-in-php-coding-help-please/#findComment-1409536 Share on other sites More sharing options...
swagpixels Posted February 1, 2013 Author Share Posted February 1, 2013 so what should i do? or change. I can't drop this one, as its a premade code. What do i change? Link to comment https://forums.phpfreaks.com/topic/273917-need-help-error-in-php-coding-help-please/#findComment-1409537 Share on other sites More sharing options...
jcbones Posted February 1, 2013 Share Posted February 1, 2013 You are not assigning your variables correctly. There is a distinct difference between the way the first 4 variables are assigned, vs. the rest of them. Everything you need to know about PHP variables! Link to comment https://forums.phpfreaks.com/topic/273917-need-help-error-in-php-coding-help-please/#findComment-1409542 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.