Harjit Singh

Ranch Hand
+ Follow
since Feb 01, 2007
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
2
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Harjit Singh

Hi there,



I have a site and when you actually go to that site via browser, it asks for basic Http authentication when the user fills in the required information, there are some cookies dropped by the site.

I tried to mimic the same behavior using XHR. when I use XHR and I look in the developer console , I do see that the cookies are there but the issue here is how do I access those ?

If I do XHR.getAllResponseHeaders() doesn't give me what I'm looking for and also if I do xhr.getResponseHeader("Set-Cookie"), I don't get the value back...



Thanks

- Harjit
Hi there,

I have a site. When I go to that site for authentiction, It prompts with a user name and password using http basic auth. After the auth is done authenticating, it actually drops a cookie if the site which the request is coming from is in the the same subdomain.

I have this piece of code






I don't see the cookies which the authentication site drops. Does anybody have any clues as to why ?

my main site for example is www.indtab.com and my subdomain site is harjit.indtab.com

Thanks

- Harjit
8 years ago
I just bought it and will look thru it.

Thanks

- Harjit
I had looked at it but I guess for some reasons the qtips were not being shown on the demo pages and hence I didn't look further. This exactly does what I need.

- Harjit
Hi there,

I have a method on my client side which actually gets some JSON data from the server which includes some images which are being displayed. How can I do the following things

1) Depending on the image on which the mouse is show price info and some other data pertinant to the item on which the mouse is hovered.

Thanks

- Harjit
Thanks for all your tips. It has helped me a lot to understand how we can do things.

- Harjit
9 years ago
JSP
Hi there,

I have 3 sites- Site A,siteB and AW site, which is the authentication site. Site A and SiteB are trusted sites. Let say when a user logs in to site A. he is re-directed back to site A and then does his work. Now when He clicks on Site B, there will be token passed to site B now before he can access the resource, he will be re-directed to AW site where the AW site has to determine is a user is logged or no.

How can I determine that ?

Thanks

- Harjit
9 years ago
JSP

Bear Bibeault wrote:Please answer the questions. When? At page load?




Yes.....

Bear Bibeault wrote:I have no idea what the "g" custom tag library is, but whatever it is that's a server-side construct that's evaluated long before the page gets to the client where JavaScript (and jQuery) is evaluated.

You'll need to explain what and when you want things to happen so we can figure out how to implement it.

If just want the jQuery function to execute on page load, you can use the if construct to include or exclude the code in the markup. If you want the function to execute based upon client-side mechanisms (such as events), server-side conditionals aren;t going to be of any help.




g is a grails tag and here I'm checking for a condition whether a user is present in the session. What I need to do is
when I have a user in the session . I need to display a popup or show a message saying that user is linked.

- Harjit
Hi there

I have a condition in my page like

<g:if test="${session.user}">

I need to execute a jQuery function which will show a dialog or a message saying User exists or something like that. How can I do that ?

thanks

- Harjit
Found the issue. It was a conditional logic error which was causing it to return false in case it was found... I guess I'm having the Monday office blues....

- H
9 years ago
Hi there

I have two actions whose code is as follows




what I see is that the action link which is called doesn't find the object when I pass the parameter, params.userName while as authenticate works fine. Any clues why this would not be working. I do see the value of userName being passed from the form to the controller.

Thanks

- Harjit
9 years ago
I'm controller includes the standard code for what a typical list method would output. It just returns a map of all the instances and the total. Couple of questions

1) How do I log what I'm getting from response ?
2) How can I just render the template ?

Thanks for your help.

- Harjit
9 years ago
here is what is happening. I had written the stuff using the <select tag and using the remotefunction in the onchange attribute. For some reasons when I update my div it actually duplicated the navigation bar.

><select id="dd"
onchange="${remoteFunction(
controller:'fnmWeeklyStatus',
action:'listall',
update:'tasklist',
before:'removeElementBefore(\'tasklist\')',
params: '\'id=\'+ this.value',
onComplete='testFailure()')}">
<option value=""></option>
<option value="ShowAll">ShowAll</option>
<option value="Mine">Mine</option>

</select>

I don't know why that's happening. I tried to take a look at the DOM and I couldn't find the references to the duplicate nav bar in the DOM and hence I wanted to see if there is any other route to take.
9 years ago
I'm having specific issues. Is there any way to submit the form with the use of an dropdown list or clicking of a check box in Grails. I want to avoid too many clicks to see the data.

Thanks

- Harjit
9 years ago