MySQL.sock error with php

Hello

I'm trying to get MySQL running on my Mac running OS X 10.5.1
The server works and I have imported one of my inside databases. However when I run Dreamweaver and try and add the new database I get this error in Dreamweaver;

Unable to connect to the local MySQL server through socket ' / var/mysql/mysql.sock' (38)

Speaking with MySQL, they said that this file is located in /tmp/
I copied and added where DW wants it but still no joy.

Thank you, Alan, the other fixed which ungrudgingly :)

Have a good Christmas!

Tags: Dreamweaver

Similar Questions

  • MySQL Sytax error with master pages and details

    Master and detail pages.
    I get a SQL error when I click on an item in the master page.
    "You have an error in your syntax SQL; "check the manual corresponding to your version of the MySQL server for the right syntax to use near 'ID = 16 LIMIT 0, 10' at line 1"
    If I try to open the details page, I get
    "You have an error in your syntax SQL; "check the manual corresponding to your version of the MySQL server for the right syntax to use near 'ID = - 1 LIMIT 0, 10' at line 1"
    I created this pair by clicking on insert/object / master details page.
    I tried this several ways, but always get the same result.
    Is there a bug in CS3?

    Sorry that I have solved it myself.
    I accidentally put a space in a header of table in the mySQL database.
    Everything works fine now.

  • Insert a special character such as apostrophes with PHP/Mysql

    Hi friends,

    I have a problem with php/mysql. I created a form vach'inton a page php with dreamweaver and when I try to fill in the form with a string that contains an apostrophe ('), I got an error. It seems that integration is not possible. Would you have any idea for that. I give you the code of dreamweaver php and thank you for your help.

    <? php require_once('Connections/Mainconnect.php');? >

    <? php require_once('Zend/Date.php');? >

    <? PHP

    If (! function_exists ("GetSQLValueString")) {}

    function GetSQLValueString ($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")

    {

    If (via PHP_VERSION < 6) {}

    $theValue = get_magic_quotes_gpc()? stripslashes ($TheValue): $theValue;

    }

    $theValue = function_exists ("mysql_real_escape_string")? mysql_real_escape_string ($TheValue): mysql_escape_string ($theValue);

    Switch ($theType) {}

    case 'text ':

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "long":

    case "int":

    $theValue = ($theValue! = "")? intval ($TheValue): 'NULL ';

    break;

    case "double":

    $theValue = ($theValue! = "")? doubleVal ($TheValue): 'NULL ';

    break;

    case "date":

    If ($theValue =="")

    {

    $theValue = "NULL";

    }

    on the other

    {

    $zendDate = new Zend_Date($theValue,"dd/MM/yyyy");

    $theValue = "" "." $zendDate-> toString("yyyy-MM-dd"). »" « ;"

    }

    break;

    case "set":

    $theValue = ($theValue! = "")? $theDefinedValue: $theNotDefinedValue;

    break;

    }

    Return $theValue;

    }

    }

    $editFormAction = $_SERVER ['PHP_SELF'];

    If (isset {}

    $editFormAction. = « ? ». htmlentities($_SERVER['QUERY_STRING']);

    }

    If ((isset($_POST["MM_update"])) & & ($_POST ["MM_update"] == "form1")) {}

    $updateSQL = sprintf ("UPDATE pers_soc_reg SET Field1 = %s, Field2 = %s,

    GetSQLValueString ($_POST ["field1"], "text").

    GetSQLValueString ($_POST ["Field2"], "double"));

    Hello friends,

    I solved the problem.

    The problem is a free extension for dreamweaver called 'check new items' of Felixone. After his retirement, all forms of work without problem.

    Thanks to you all.

  • I get this error with my login form, I did, but I'm not sure if this is a problem with my php code or

    I get this error with my login form when I try to log in, but I'm not sure if this is a problem with my php code or my flex code!

    ReferenceError: Error #1069: loginsuccess property not found on string and there is no default value.
    CBC::main/checkLogin()
    CBC::main/__login_user_result()
    to flash. events::EventDispatcher / dispatchEv...
    to flash. events::EventDispatcher / dispatchEv...
    to HTTPOperation / http://www.Adobe.com/2006/Flex/MX/internal:dispatchRpcEvent ()
    to mx.rpc::AbstractInvoker / http://www.Adobe.com/2006/Flex/MX/internal:resultHandler ()
    at mx.rpc::Responder/result()
    at mx.rpc::AsyncRequest/acknowledge()
    to the DirectHTTPMessageResponder/completeHandl...
    to flash. events::EventDispatcher / dispatchEv...
    to flash. events::EventDispatcher / dispatchEv...
    at flash.net::URLLoader/onComplete()


    my php code is:


    [php] <? PHP

    define ("DATABASE_SERVER", "localhost");

    define ('DATABASE_USERNAME","f4r");

    define ('DATABASE_PASSWORD', 'cool23');

    define ('database_name', 'bignixs1');

    connect to the database

    $mysql = mysql_connect (DATABASE_SERVER, DATABASE_USERNAME, DATABASE_PASSWORD) or die (mysql_error ());

    Select the database

    @mysql_select_db (DATABASE_NAME);

    re-branded the data passed from Flex to variables

    $username = mysql_real_escape_string ($_POST ["usernam...)

    $password = mysql_real_escape_string ($_POST ["passwor...)

    Ask the database to see if the combination of username/password given name is valid.

    $query = "SELECT * from users WHERE username = 'username' AND password = 'password" ";

    $result = mysql_fetch_array (mysql_query ($query));

    start generating XML

    $output = "< loginsuccess > ';

    If the query returned true, exit < loginsuccess > Yes < / loginsuccess > other output < loginsuccess > not < / loginsuccess >

    if(!$result)

    {

    $output. = « no » ;

    } else {}

    $output. = "yes";

    }

    $output. = "< / loginsuccess > ';

    all the XML for output

    print ($output);

    ? > [/php]

    $query = "SELECT * from users WHERE username = 'username' AND password = 'password" ";

    should be

    $query = "SELECT * FROM users WHERE username = '$username' AND password =  '$password'";
    

    example of a system of working with the correct connection code flex & php to ensure:

    http://www.mattlefevre.com/viewExample.php?tut=flexPHP&proj=simple%20Login%20Application

  • Save my Clip Positions of film with PHP and MySQL

    Hello

    I created a video (FLV) Player, who just plays my videos. Everything works fine and I would like to add a new button to save the position according to which the film played up to. So I can come back later and have the opportunity to play the film to the point that the last time he was arrested. Therefore, I need to save my Clip Positions of film with PHP and MySQL.

    So far, I created a button that saves the position of the my video clip "ns.time' in a variable. I'm currently just display this variable, but I need to export to my file PHP where it gets sorted to be sent to mySQL database. Could you tell m e how can be down or where I can find more material (tutorial) to achieve this.

    I tried to export using 'getURL(url,window,method)' that points to my PHP file. But for some reason any when he sends some information to my php and not only the Position of Movie Clip. I realized from the address line that attempts to send millions of movie flow information, etc..

    I realized that Flash tries to send information of my Listbox and trees which are the list of film clips I have. I don't know why he's trying to send this information! Is anyway I can stop the Flash to send information to my PHP file and send only the value of my a Variable?

    Here's how I send the value of the Variable entry in the PHP file...

    getURL (" http://www.myDomainName.com/aishopper/test2/matrix.php","", "GET" ");

    Thank you so much and have a great day.

    Babak

    Hello JayCharles,

    Thanks for your suggestion. You are absolutely correct, and made me aware of the error I made. I used your suggestion and it has worked very well. Once again, thank YOU for your help.

    See you soon,.

    Babak: o).

  • Server error: Configure 9i with php

    Respected
    I want to configure oracle 9i 9.2.0.1.0 with php on windows xp version. First I tried with apache 2, but it has been clashing with oracle apache so I installed appserv 2.6.0 and given port 81 for the 'localhost:81 '. In this way, I managed to run the simple program php ' hello world ' using 'localhost:81/test/hello.php', but when I run the connected program (check below) it gives * "Web site has encountered an error when retrieving the http://localhost:81/test/test1.php. It is perhaps out of service for maintenance or configured incorrectly. * error HTTP 500 (Internal Server Error): an unexpected condition has occurred while the server attempted to respond to the request.
    I did it due to changes in php.ini and http.conf
    1 kept php.ini in c:\windows
    2. set the doc_root
    3 - extension_dir
    4 - session.save_path = "c:\temp"
    5 uncomment the line extension = php_oci8.dll
    http.conf
    1 - Allowoverride None for all
    2 - Element DirectoryIndex is set with index.php
    3 AddType command for php "AddType application/x-http - php.php ' value
    4 - LoadModule php6_module has been defined with 'LoadModule php6_module C:/AppServ\php\php6apache2_2.dll' Remeber appserv uses php 6 and I couldn't find "php_oracle.dll" in the post of php6

    Program online
    <? PHP
    $conn = oci_connect('scott@orcl','tiger','//localhost:81/orcl');
    {if(!$conn)}
    $m = oci_error ();
    echo $m ['message'], "\n";
    "exit";
    }
    on the other
    {
    print 'connected to oracle. "
    }
    oci_close ($conn);
    ? >

    * 2nd program *.
    <? PHP
    <?
    If ($conn = Ora_Logon ("scott@orcl","tiger")) {}
    echo "< B > SUCCESS! Connected to the database < B > \n";
    }
    on the other
    {
    echo "< B > Failed < B > \n";
    }
    Ora_Logoff ($conn);
    phpinfo();
    ? >
    Please help me where I'm wrong, I want to run php on the same computer where the database resides.

    Published by: 885098 November 2, 2011 12:03

    1. I haven't looked AppsServ. If it is the same that I Googled, then it looks like an older version of PHP.
    You might consider looking at Zend Server instead.

    2. Yes you need not software customer Oracle if PHP & Oracle DB are on the same machine. But if
    your PHP OCI8 dll built to require a minimum version of Oracle and your DB libraries
    is not equal to or greater than this version, then you will need to (a) get the minimum version of the Oracle
    libraries or (b) recompile PHP yourself.

  • Send an email with php and mysql

    I want a visitor to my site click on a field in mysql to email with a BCC to me also, I want the link to show 'Send an email' not the e-mail address of the field

    There is no way to hide a BCC address with a mailto link, because it just opens the e-mail program of the user with the address fields filled in.

    What I would recommend is to create a contact form, as described in Chapter 5 of PHP Solutions. Using PHP to send the form hides your email address and all BCC addresses. It appears from your description that the email will be sent to different people according to which the link is clicked. If this is the case, the programming becomes more complex, but you can solve this problem, once you have learned how to create a contact form and email with PHP.

    I hope PHP Solutions is sufficient for your needs, but I warn you to take Chapter 3 slowly. Do not try to memorize everything in Chapter 3. Just have a general idea for how the language is structured and re-enter the chapter whenever you need to refresh your memory. If you feel the need for another book, I think that the books of Visual Quick Start of Larry Ullman are good.

  • Call to undefined function getsqlvaluestring() with PHP mysql Dreamweaver

    Hey guys, I'm new to the forum and it seems very useful. I think I have a unique problem well.

    Although this script worked for a year or two, all of a sudden, during the holidays, he went to hay

    Front end is always get all the information, it must be the Database.But when I try to connect through the side admin I created with php and database of dreamweaver extensions normal I get this error.

    I do not know many php - then I'll hide the chain at the moment - if I need to paste the code that I'll - thank you in advance


    Fatal error
    : Call to undefined function getsqlvaluestring() in /xxxxx/xxxx/xxxxxxx/xxxxxxx/newsletters/xxxxxxx/xxxxxxx/admin/login.php on line 22

    Vicinity of line 22 looks like this

    @mysql_select_db ($database_promocenter, $promocenter);

    $LoginRS__query = sprintf ("SELECT username, password, destination_page FROM users WHERE username = %s AND password is %s",

    GetSQLValueString ($loginUsername, "text"), GetSQLValueString ($password, "int"));

    $LoginRS = mysql_query ($LoginRS__query, $promocenter) or die (mysql_error ());

    $loginFoundUser = mysql_num_rows ($LoginRS);

    If {($loginFoundUser)

    First part looks like this

    < form id = "form1" name = "form1" method = "POST" action = "<?" PHP echo $loginFormAction;? > ">"
    < b >
    < td bgcolor = "#dedede" >
    < table width = "400" border = "0" align = "center" cellpadding = '3' cellspacing = "0" bgcolor = "#ffffff" >
    < b >
    < td height = "35" align = "right" valign = "middle" id = "description" > user name: < table >
    < height td = "35" > < label >
    < input style = "height: 20px;" border: 1px solid #999999 "name ="username"type ="text"id ="username"size ="35"/ >"
    < / label > < table >
    < /tr >
    < b >
    < td height = "35" align = "right" valign = "middle" id = "description" > password: < table >
    < height td = "35" > < label >
    < input style = "height: 20px;" border: 1px solid #999999 "name ="password"type ="password"id ="password"size ="35"/ >"
    < / label > < table >
    < /tr >

    Anton

    Could also show you it could never work.  Why?  Because the call to the function is made before the function is defined.  He would always stop execution with an undefined function error.

    Now - it seems that you have added the users authentication that was placed before the code block in which the function is defined.  So I would say that you move it-

    If (! function_exists ("GetSQLValueString")) {}

    function GetSQLValueString ($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")

    {

    If (via PHP_VERSION< 6)="" {="" 6)="">

    $theValue = get_magic_quotes_gpc()? stripslashes ($TheValue): $theValue;

    }

    $theValue = function_exists ("mysql_real_escape_string")? mysql_real_escape_string ($TheValue): mysql_escape_string ($theValue);

    Switch ($theType) {}

    case 'text ':

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "long":

    case "int":

    $theValue = ($theValue! = "")? intval ($TheValue): 'NULL ';

    break;

    case "double":

    $theValue = ($theValue! = "")? doubleVal ($TheValue): 'NULL ';

    break;

    case "date":

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "set":

    $theValue = ($theValue! = "")? $theDefinedValue: $theNotDefinedValue;

    break;

    }

    Return $theValue;

    }

    }

    from its current location to a new block just under the connection with the directive, i.e.,.

    MOVE HERE ? >

    <>

    Validate request to connect to this site.

    so that the final code looks like this-

    <>

    If (! function_exists ("GetSQLValueString")) {}

    function GetSQLValueString ($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")

    {

    If (via PHP_VERSION< 6)="">

    $theValue = get_magic_quotes_gpc()? stripslashes ($TheValue): $theValue;

    }

    $theValue = function_exists ("mysql_real_escape_string")? mysql_real_escape_string ($TheValue): mysql_escape_string ($theValue);

    Switch ($theType) {}

    case 'text ':

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "long":

    case "int":

    $theValue = ($theValue! = "")? intval ($TheValue): 'NULL ';

    break;

    case "double":

    $theValue = ($theValue! = "")? doubleVal ($TheValue): 'NULL ';

    break;

    case "date":

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "set":

    $theValue = ($theValue! = "")? $theDefinedValue: $theNotDefinedValue;

    break;

    }

    Return $theValue;

    }

    }

    ?>

    <>

    Validate request to connect to this site.

  • Price with PHP/MySQL

    I want to use numbers from a database, prices. In the database (PHP/MySQL), the structure is ' decimal (9.2). If I put it out with PHP a number as is €9.02 9,02 but 9.20 looks like this €9,2. How can I set prices with PHP/MySQL?

    I hope that my question is simple... Thankx for any other help.

    Use number_format() functionof PHP.

  • libphp7.so error with httpd.2.4.18 - symbol not found: __cg_jpeg_resync_to_restart

    I am creating a web development environment that has the same platform of LAMP as my production server to minimize the conflicts of the possibility.  The production server has been implemented with Apache with PHP 7.0.2 Update 2.4.18, installed and running.

    I have everything installed in/usr/local from sources on the production server (AWS EC2 running Linux).  I'm trying to repeat the process on the Macbook Pro under OS X 10.11.3.  So far, I got no problem with compiling, installing and loading of the mysql servers both httpd.

    I am able to compile PHP7 without errors.  I installed FreeType 2.6.2 and 9B LibJPEG, libPNG 1.6.21 in/usr/local and compiled PHP with the following configuration:

    . / configure-prefix = / usr/local-with-config-file-path = / usr/local/etc-with-config-file-scan-dir = / usr/local/etc/php-with-apxs2 = / usr/local/bin/apxs-enable-calendar-enable-cli-enable-exif-enable-ftp-enable-pcntl-enable-shmop-enable-sockets-enable-wddx-enable-zip-with-bz2-with-curl--with-gd-with-freetype-dir = / usr/local-with-jpeg-dir = / usr/local-with-png-dir = / usr/local-with-imap-ssl-with-mysqli = mysqlnd--with-mysql-sock=/tmp/mysql.sock - with-openssl-with-openssl-dir = / usr/local-with-pdo-mysql = mysqlnd - with-pear - with-libedit - with-xsl - with-zlib

    PHP compiles and installs without error.  The CLI binary answers without error:

    $ php - v

    PHP 7.0.2 (cli) (built: 6 February 2016 22:02:36) (NTS)

    Copyright (c) 1997-2015 the PHP Group

    Zend Engine v3.0.0, Copyright (c) 1998-2015 Zend Technologies

    However, when I try to load Apache, I get an error:

    $ sudo/usr/local/sbin/apachectl t

    httpd: syntax on line 150 of /usr/local/etc/httpd.conf error: cannot load libexec/libphp7.so into server: dlopen (/ usr/local/libexec/libphp7.so, 10): symbol not found: __cg_jpeg_resync_to_restart\n referenced from: /System/Library/Frameworks/ImageIO.framework/Versions/A/Resources/libTIFF.dylib \n expected: /usr/local/lib/libjpeg.9.dylib\n to /System/Library/Frameworks/ImageIO.framework/Versions/A/Resources/libTIFF.dylib

    Based on the contribution of the research on Google, I modified the file/usr/local/sbin/envvars and /usr/local/sbin/envvars-std.

    Originally:

    If test "x$ DYLD_LIBRARY_PATH"! = « x » ; then

    DYLD_LIBRARY_PATH = "" / usr/local/lib: $DYLD_LIBRARY_PATH ""

    on the other

    DYLD_LIBRARY_PATH = ' / usr/local/lib '.

    FI

    Under the direction of:

    If test "x$ DYLD_LIBRARY_PATH"! = « x » ; then

    DYLD_LIBRARY_PATH = ' / usr/local/lib '.

    on the other

    DYLD_LIBRARY_PATH = ' / usr/local/lib '.

    FI

    Export DYLD_LIBRARY_PATH

    Based on more googling, I ran otools on the binaries to try to ascertain where libTIFF.dylib is referenced.

    $ otool-L /usr/local/libexec/libphp7.so

    /usr/local/libexec/libphp7.so:

    /usr/local/lib/libaprutil-1.0.dylib (compatibility version 6.0.0 latest version 6.4.0)

    /usr/lib/libexpat.1.dylib (compatibility version 7.0.0, latest version 8.0.0)

    /usr/lib/libiconv.2.dylib (compatibility version 7.0.0, latest version 7.0.0)

    /usr/local/lib/libapr-1.0.dylib (compatibility version 6.0.0 latest version 6.2.0)

    /usr/lib/libSystem.B.dylib (version 1.0.0 of compatibility, the current version 1226.10.1)

    /usr/lib/libz.1.dylib (version 1.0.0 compatibility, latest version 1.2.5)

    /usr/lib/libexslt.0.dylib (version 9.0.0 of compatibility, the current version 9.15.0)

    /usr/lib/libresolv.9.dylib (version 1.0.0 compatibility, latest version 1.0.0)

    /usr/lib/libedit.3.dylib (version 2.0.0 compatibility latest version 3.0.0)

    /usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0 latest version 5.4.0)

    /usr/local/lib/libpng16.16.dylib (version compatibility, the current version 38.0.0 38.0.0)

    /usr/local/lib/libjpeg.9.dylib (compatibility version 12.0.0, latest version 12.0.0)

    /usr/lib/libcurl.4.dylib (compatibility version 7.0.0, latest version 8.0.0)

    /usr/lib/libbz2.1.0.dylib (version 1.0.0 compatibility, latest version 1.0.5)

    /usr/lib/libxml2.2.dylib (version 10.0.0 compatibility, the current version 10.9.0)

    / usr/lib/libicucore. A.dylib (version 1.0.0 of compatibility, the current version 55.1.0)

    /usr/local/lib/libfreetype.6.dylib (version compatibility, the current version 19.2.0 19.0.0)

    /usr/lib/libxslt.1.dylib (version 3.0.0 of compatibility, the current version 3.26.0)

    $ otool-L /usr/local/lib/libjpeg.9.dylib

    /usr/local/lib/libjpeg.9.dylib:

    /usr/local/lib/libjpeg.9.dylib (compatibility version 12.0.0, latest version 12.0.0)

    /usr/lib/libSystem.B.dylib (version 1.0.0 of compatibility, the current version 1226.10.1

    I am at a loss.  I don't see how and where libTIFF.dylib system is referenced, and what I can do to fix this so PHP7 compiles purely against the library libjpeg in/usr/local.

    Any help and guidance will be greatly appreciated.

    You will have a much better chance to get this stuff free to work if you are using a build system such as 'MacPorts,' 'HomeBrew', or 'Fink '. You will also have access to mailing lists where you might find others who have solved the same problem you have. There is virtually no chance of finding someone like that here.

  • Unable to connect to the local MySQL server through socket ' / var/lib/mysql/mysql.sock' #2 #.

    I received an email indicating that HP does not show me as having all printers which explains why I have not received information of driver update I guess.  But when I typed in HP4500 G510, I received the following error message:

    Unable to connect to the local MySQL server through socket ' / var/lib/mysql/mysql.sock' #2 #.

    And since I don't know beans about computers, I don't have any idea what it means.

    Because I had to pick a topic, I chose the one above, but no other choices were nowhere near cover.

    Hi mac64.
    I understand you are trying to register for updates for your Officejet 4500. I can certainly help you with this.

    I'll give you a link to try to register for driver updates. Please let me know if it's the same link you used and if this works differently for you, simply click on the following link: the HP driver updates.

    Hope to hear from you soon

  • code snippets in color behavior plan DW in file with php

    Hello

    I have a PHP file loaded in DW.

    In this file are several HTML + PHP code snippets.

    The color scheme (on screen) of the HTML components is not the same in different parts of this file... Is this normal... or is it a mistake?

    It seems that the file is OK running in php.

    question:

    Snippets of HTML code of the system color (ie) are identical in all of the file?

    Fred K. says:

    Hello

    I have a PHP file loaded in DW.

    In this file are several HTML + PHP code snippets.

    The color scheme (on screen) of the HTML components is not the same in different parts of this file... Is this normal... or is it a mistake?

    It seems that the file is OK running in php.

    question:

    Snippets of HTML code of the system color (ie) are identical in all of the file?

    Looks like there is probably an error in your markup somewhere. Snippets of html code must be the same color except that you generate a script to mail electronic html or maybe a message of the form.

    If there is an error in the supplement of php, it would be unusual for the page to show anything it either - look so the html code.

    EDITED.

    In FACT if you are echoing of html with php elements that might be a different color, usually red in DW, identical to the php code.

  • Invalid accept header with PHP SDK 5.1 against 1.5.1 vCloud Director

    In PHP 5.1 SDK samples do not work against 1.5.1 vCloud Director?  Any code that I am trying to write with PHP 5.1 SDK really will work against my vCD 1.5.1?  Or it will fail as the samples?  Is there something I can do for samples and all this work?

    My question seems very similar to http://communities.vmware.com/message/2142668#2142668.  I've had some success with the SDK 1.5 samples against my 1.5.1 vCloud Director.  But when I've upgraded to the PHP 5.1 SDK, all I could get was "invalid accepts header" messages, like this:

    PHP Fatal error: Eception exception 'VMware_VCloud_SDK_Exception' with the message "POST ". https://vCloud.mydomain.edu/API/login failed, return code: 400, error: <? xml version = "1.0" encoding = "UTF-8"? >

    " < error xmlns =" http://www.VMware.com/vCloud/v1.5 "stackTrace =" com.vmware.vcloud.api.rest.handlers.exceptions.BadRequestRestApiException: invalid application accepts the header

    at com.vmware.vcloud.api.rest.common.handlers.ErrorHandler.getBadRequestApiException(ErrorHandler.java:71)

    at com.vmware.vcloud.api.rest.common.handlers.ErrorHandler.errorBadRequest(ErrorHandler.java:44)

    at sun.reflect.GeneratedMethodAccessor11639.invoke (unknown Source)

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

    at java.lang.reflect.Method.invoke(Method.java:597)

    at org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:173)

    at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:89)

    at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:133)

    to org.ap in /home/bob/lib/vcloudPHP-5.1.0/library/VMware/VCloud/ServiceAbstract.php on line 178

    After changing VCLOUD_API_VERSION in library/VMware/VCloud/Constants.php of 5.1 to 1.5, I get this:

    PHP Fatal error: Eception exception 'VMware_VCloud_SDK_Exception' with the message "POST ". https://vCloud.mydomain.edu/API/login failed, return code: 401 error,:, request data:
    ' in /home/bob/lib/vcloudPHP-5.1.0/library/VMware/VCloud/ServiceAbstract.php:178
    Stack trace:
    #0 home/bob/lib/vcloudPHP-5.1.0/library/VMware/VCloud/Service.php(114): VMware_VCloud_SDK_Service_Abstract-> message ('https://vcloud...) "(, 200) "
    #1 home/bob/lib/vcloudPHP-5.1.0/samples/login.php(78): VMware_VCloud_SDK_Service-> login ('vcloud.mydomain...', Array, Array)
    #2 {hand}
    lifting in /home/bob/lib/vcloudPHP-5.1.0/library/VMware/VCloud/ServiceAbstract.php on line 178

    A standard API call seems to work:

    curl - test id = true u scripty@system h ' Accept: application / * + xml; " version 1.5 =" https://vCloud.mydomain.edu/API/sessions

    Enter password for the user "scripty@system": Home


    HTTP/1.1 200 OK

    Date: Wednesday, November 28, 2012 17:43:56 GMT

    x vcloud-authorization: rxpTQIswdd15HNz + hZku6BCutGljF5VLUrt0M8x + IGI =

    Set-Cookie: vcloud-token = rxpTQIswdd15HNz + hZku6BCutGljF5VLUrt0M8x IGI plus; Guarantee; Path = /.

    Content-Type: application/vnd.vmware.vcloud.session+xml;version=1.5

    Date: Wednesday, November 28, 2012 17:43:56 GMT

    Content-Length: 1009


    <? XML version = "1.0" encoding = "UTF-8"? >

    " < session xmlns =" http://www.VMware.com/vCloud/v1.5 "user = org"scripty' = 'System' type="application/vnd.vmware.vcloud.session+xml' href =" https://vCloud.mydomain.edu/API/session/ "" xmlns: xsi = " http://www.w3.org/2001/XMLSchema-instance " xsi: schemaLocation = " http://www.VMware.com/vCloud/v1.5 http://vcloud.the.usg.edu/api/v1.5/schema/master.xsd" > "" "

    "" < link rel = "low" type="application/vnd.vmware.vcloud.orgList+xml" href = " https://vCloud.mydomain.edu/API/org/ "/>

    "" < link rel = "low" type="application/vnd.vmware.admin.vcloud+xml" href = " https://vCloud.mydomain.edu/API/Admin/ "/>

    "" < link rel = "low" type="application/vnd.vmware.admin.vmwExtension+xml" href = " https://vCloud.mydomain.edu/API/admin/extension "/>

    "" < link rel = "low" type="application/vnd.vmware.vcloud.query.queryList+xml" href = " https://vCloud.mydomain.edu/API/query "/>

    "" < link rel = "entityResolver" type="application/vnd.vmware.vcloud.entity+xml" href = " https://vCloud.mydomain.edu/API/entity/ "/>

    < / session >

    Version switching in gross 1.5 to 5.1 API call causes the accept header message invalid, which is not surprising, now that I became familiar with the format and the requirement to accept header.
    For example, can code samples from the SDK 5.1 actually work against 1.5.1 API?
    Thank you!!!

    Hello

    PHP Fatal error: Eception exception 'VMware_VCloud_SDK_Exception' with message "POST https://vcloud.mydomain.edu/api/login failed, return code: 401 error,:, request data:"

    [Rajesh] Seems to me like a problem of password username. As it clearly says 401.

    After changing VCLOUD_API_VERSION in library/VMware/VCloud/Constants.php of 5.1 to 1.5, I get this:

    [Rajesh] SDK users should not change the code in the library. This is a bug with the SDK for not allowing users to change the version of API through the library (connection method accepts the version as well) rather than change in the library.
    Kind regards
    Rajesh Kamal.
  • Creation of lists of goods make a DWCS5 recordset with php PLS help

    Hi there I have an another question on lists with php and the Recordset.

    Here is my example:

    < ul >

    < li > let us all live < /li >

    Help my soul. < /li > < li > to

    < li > please have a life wonderfull. < /li >

    < li > you want another. < /li >

    < li > will you help me with. < /li >

    < li > let us go now. < /li >

    < /ul >

    I have all these lines of text in a table all in lines in my mysql database all have an id, I need to post it on my site as my example above, don't know where start because all the examples I have seen are nested lists someone can help. When I create my recordset and use the repeat region I get 'let us all live. Help my soul. Please have a wonderful life. You will assist me with. Let us go now. »

    Here is my code

    <? PHP

    If (! function_exists ("GetSQLValueString")) {}

    function GetSQLValueString ($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")

    {

    If (via PHP_VERSION < 6) {}

    $theValue = get_magic_quotes_gpc()? stripslashes ($TheValue): $theValue;

    }

    $theValue = function_exists ("mysql_real_escape_string")? mysql_real_escape_string ($TheValue): mysql_escape_string ($theValue);

    Switch ($theType) {}

    case 'text ':

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "long":

    case "int":

    $theValue = ($theValue! = "")? intval ($TheValue): 'NULL ';

    break;

    case "double":

    $theValue = ($theValue! = "")? doubleVal ($TheValue): 'NULL ';

    break;

    case "date":

    $theValue = ($theValue! = "")? « " ». $theValue. "" "": "NULL";

    break;

    case "set":

    $theValue = ($theValue! = "")? $theDefinedValue: $theNotDefinedValue;

    break;

    }

    Return $theValue;

    }

    }

    @mysql_select_db ($database_datexdatabase, $datexdatabase);

    $query_rsSwiftPOStableFeatures = "SELECT title, discribtion of id ORDER BY 'restaurant table service' ASC ';

    $rsSwiftPOStableFeatures = mysql_query ($query_rsSwiftPOStableFeatures, $datexdatabase) or die (mysql_error ());

    $row_rsSwiftPOStableFeatures = mysql_fetch_assoc ($rsSwiftPOStableFeatures);

    $totalRows_rsSwiftPOStableFeatures = mysql_num_rows ($rsSwiftPOStableFeatures);

    ? >

    < div id = "content" > <? PHP {? >}

    <? PHP echo $row_rsSwiftPOStableFeatures ["discribtion"];? >

    <? PHP} while ($row_rsSwiftPOStableFeatures = mysql_fetch_assoc ($rsSwiftPOStableFeatures));? >

    < / div >

    Concerning

    Just change this:

    To do this:

    • «. $row_rsSwiftPOStableFeatures ["discribtion"]. »
    • "; ?>

    Also I recommend you strongly to read on the basics of PHP programming to understand these things, because while that DW gives you a good starting point, once you want to raise with you will need to understand the code.

  • Using Incontext editing with PHP pages

    Hello
    Has anyone established if you use incontext editing with php pages. My site works perfectly except for the pages that I created in php. The reason I used php, it is that they are sure that only certain users can access.

    The error message that appears is: "no input file specified." But the page is in place.

    Thanks in advance for any help that anyone can provide.

    Chris

    In the hope that I could save someone else the headache of this troubleshooting, I found that the javascript call

    conflicts with other javascript on my website called "defineFunctions.js".
    ()
    By removing this second call javascript, Incontext Editing now works. Not savvy enough to understand why he was conflicted. The only thing in defineFunctions.js is a popup window script.

Maybe you are looking for