Jump to:

7940 Posts in 1543 Topics by 946 members

DataObjectManager Module

SilverStripe Forums » DataObjectManager Module » uploadify problem <h1> bad request (Invalid hostname) </h1>

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1314 Views
  • ravik
    Avatar
    Community Member
    10 Posts

    uploadify problem <h1> bad request (Invalid hostname) </h1> Link to this post

    hi everyone,

    I am using silverstripe 2.4.7 it is working fine, The thing is from last one month uploadify module is working fine in my localhost,
    but suddenly it giving error like "<h1> bad request (Invalid hostname) </h1>" in localhost.

    after that i enable the firefox firebug, so now i am getting response from firebug is

    ERROR [User Error]: Couldn't run query:
    SELECT "File"."ClassName", "File"."Created", "File"."LastEdited", "File"."Name", "File"."Title", "File"."Filename", "File"."Content", "File"."Sort", "File"."ShowInSearch", "File"."SortOrder", "File"."ParentID", "File"."OwnerID", "File"."ID", CASE WHEN "File"."ClassName" IS NOT NULL THEN "File"."ClassName" ELSE 'File' END AS "RecordClassName"
    FROM "File"
    WHERE ("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>))
    ORDER BY "SortOrder" ASC

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC' at line 1
    IN GET /nesso/index.php/admin/assets/EditForm/field/Files/UploadifyForm/field/UploadedFiles/refresh?SecurityID=6b50d9fb8fd164f81ab57b19593446690749745d&ctf[Files][start]=0&ctf[Files][per_page]=10&ctf[Files][showall]=0&ctf[Files][sort]=SortOrder&ctf[Files][sort_dir]=&ctf[Files][search]=&ctf[Files][filter]=&ctf[Files][view]=&FileIDs=%3Ch1%3EBad+Request+(Invalid+Hostname)%3C%2Fh1%3E
    Line 525 in /var/www/nesso/sapphire/core/model/MySQLDatabase.php

    Source
    ======
    516:    }
    517:    
    518:    function databaseError($msg, $errorLevel = E_USER_ERROR) {
    519:       // try to extract and format query
    520:       if(preg_match('/Couldn\'t run query: ([^\|]*)\|\s*(.*)/', $msg, $matches)) {
    521:          $formatter = new SQLFormatter();
    522:          $msg = "Couldn't run query: \n" . $formatter->formatPlain($matches[1]) . "\n\n" . $matches[2];
    523:       }
    524:       
    * 525:       user_error($msg, $errorLevel);
    526:    }
    527:    
    528:    /**
    529:     * Return a boolean type-formatted string
    530:     *
    531:     * @param array $values Contains a tokenised list of info about this data type

    Trace
    =====
    <ul>user_error(Couldn't run query:
    SELECT "File"."ClassName", "File"."Created", "File"."LastEdited", "File"."Name", "File"."Title", "File"."Filename", "File"."Content", "File"."Sort", "File"."ShowInSearch", "File"."SortOrder", "File"."ParentID", "File"."OwnerID", "File"."ID", CASE WHEN "File"."ClassName" IS NOT NULL THEN "File"."ClassName" ELSE 'File' END AS "RecordClassName"
    FROM "File"
    WHERE ("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>))
    ORDER BY "SortOrder" ASC

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC' at line 1,256)
    line 525 of MySQLDatabase.php

    MySQLDatabase->databaseError(Couldn't run query: SELECT "File"."ClassName", "File"."Created", "File"."LastEdited", "File"."Name", "File"."Title", "File"."Filename", "File"."Content", "File"."Sort", "File"."ShowInSearch", "File"."SortOrder", "File"."ParentID", "File"."OwnerID", "File"."ID", CASE WHEN "File"."ClassName" IS NOT NULL THEN "File"."ClassName" ELSE 'File' END AS "RecordClassName" FROM "File" WHERE ("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC | You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC' at line 1,256)
    line 123 of MySQLDatabase.php

    MySQLDatabase->query(SELECT "File"."ClassName", "File"."Created", "File"."LastEdited", "File"."Name", "File"."Title", "File"."Filename", "File"."Content", "File"."Sort", "File"."ShowInSearch", "File"."SortOrder", "File"."ParentID", "File"."OwnerID", "File"."ID", CASE WHEN "File"."ClassName" IS NOT NULL THEN "File"."ClassName" ELSE 'File' END AS "RecordClassName" FROM "File" WHERE ("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC,256)
    line 129 of DB.php

    DB::query(SELECT "File"."ClassName", "File"."Created", "File"."LastEdited", "File"."Name", "File"."Title", "File"."Filename", "File"."Content", "File"."Sort", "File"."ShowInSearch", "File"."SortOrder", "File"."ParentID", "File"."OwnerID", "File"."ID", CASE WHEN "File"."ClassName" IS NOT NULL THEN "File"."ClassName" ELSE 'File' END AS "RecordClassName" FROM "File" WHERE ("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>)) ORDER BY "SortOrder" ASC,256)
    line 404 of SQLQuery.php

    SQLQuery->execute()
    line 761 of File.php

    File->instance_get("File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>),,,,DataObjectSet)
    line 2714 of DataObject.php

    DataObject::get(File,"File"."ID" IN (<h1>Bad Request (Invalid Hostname)</h1>))
    line 182 of MultipleFileUploadField.php

    MultipleFileUploadField->Files()
    line 369 of ViewableData.php

    ViewableData->obj(Files,,,1,)
    line 411 of ViewableData.php

    ViewableData->cachedCall(Files,)
    line 424 of ViewableData.php

    ViewableData->hasValue(Files)
    line 11 of .cache.uploadify.templates.Includes.AttachedFiles.ss

    include(/tmp/silverstripe-cache-var-www-nesso/.cache.uploadify.templates.Includes.AttachedFiles.ss)
    line 429 of SSViewer.php

    SSViewer->process(MultipleFileUploadField)
    line 342 of ViewableData.php

    ViewableData->renderWith(AttachedFiles)
    line 128 of MultipleFileUploadField.php

    MultipleFileUploadField->refresh(SS_HTTPRequest)
    line 143 of RequestHandler.php

    RequestHandler->handleRequest(SS_HTTPRequest)
    line 161 of RequestHandler.php

    RequestHandler->handleRequest(SS_HTTPRequest)
    line 161 of RequestHandler.php

    RequestHandler->handleRequest(SS_HTTPRequest)
    line 161 of RequestHandler.php

    RequestHandler->handleRequest(SS_HTTPRequest)
    line 161 of RequestHandler.php

    RequestHandler->handleRequest(SS_HTTPRequest)
    line 147 of Controller.php

    Controller->handleRequest(SS_HTTPRequest)
    line 282 of Director.php

    Director::handleRequest(SS_HTTPRequest,Session)
    line 125 of Director.php

    Director::direct(admin/assets/EditForm/field/Files/UploadifyForm/field/UploadedFiles/refresh)
    line 127 of main.php

    require_once(/var/www/nesso/sapphire/main.php)
    line 63 of index.php

    </ul>

    Please anyone help me.

    1314 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.