Solved

Javascript/Jquery SharePoint

Posted on 2011-09-27
3
183 Views
Last Modified: 2012-05-12
Hello all,

I have a code that searches a page and then highlights the information that is found. I would like to create a code that if it is not on page A then it should stop and search page B. If it is not on both pages then it will return nothing. Below is the code that I have that searches a page.

$("body").delegate("#inoiceNumber_a", "click", function(e){
      JumpAndSearch("#inoiceNumber", "si_", "#divSearchErrorMsg", SPSITENAME + "invoiceInformation.aspx");
});


Now if I can only let it search two pages if it doesn't get it in the first page.

Thanks in advance.
0
Comment
Question by:Isaac
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Expert Comment

by:danbaugher
ID: 36711471
You can't access more than 1 page at a time in jQuery. You would need to code this on the backend or load the second page inside of the first page with ajax.
0
 
LVL 5

Author Comment

by:Isaac
ID: 36711660
Oh ok. Well can jQuery do a window pop for the second page. If so I can it be done?
0
 
LVL 1

Accepted Solution

by:
danbaugher earned 500 total points
ID: 36712119
Yes you could load the second window in a popup or lightbox and do your highlighting from there. You could pass the information to be highlighted after a hash tag, then have your ready function check for the existence of that hash tag and highlight content.
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question