The Lodge is members-only design/dev videos and Office Hours.

Next Office Hours Session: "Implementing an SVG Icon System" Nov 30 - 6:00 PM Eastern

Jquery get and post

  • # April 17, 2013 at 4:51 pm

    I have some JavaScript that is trying to Ajax to a file on someone else’s server and I need to send post ang hat data at the same time but I can’t.

    # April 17, 2013 at 5:18 pm

    Help someone

    # April 17, 2013 at 5:38 pm

    Not sure if that’s even possible with same origin policy.

    # April 17, 2013 at 5:39 pm


    # April 17, 2013 at 5:59 pm

    Did you just made an alias to piss on @Htmlmaniac?

    # April 18, 2013 at 1:40 am

    Yes he thinks I’m a spammer. And I’m using jsonp to get round the same origin policy.

    # April 18, 2013 at 1:43 am

    I’m using and I have access to the file with custom html for the bot but it has to be on their server.

    # April 18, 2013 at 1:43 am

    to properly use jsonp the requested json code should be wrapped in a function call which you have to declare on your code before making the call.Also the error logged in the console could help

    # April 18, 2013 at 1:53 am

    I am doing that but it need to send get data in the url to get to the bot and post data to send the input and session id

    # April 18, 2013 at 2:06 am

    type: “GET”,
    url: “”,
    dataType: “jsonp”

    give this one a try [edited insert callback in the query]

    # April 18, 2013 at 2:16 am

    Yes but i need to do this:

    url: ‘’,
    data: {
    ‘input’: text
    dataType: ‘jsonp’,
    jsonpCallback: ‘jsonp’,
    type: ‘POST’,
    success: function (data) {

    # April 18, 2013 at 3:25 am

    I sorted it with ajaxing to a php file witch did a curl to the file i was previously ajaxing to.

Viewing 12 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed