Current location: Hot Scripts Forums » General Web Coding » JavaScript » Newbie help! breacrumb starting Subdirectory


Newbie help! breacrumb starting Subdirectory

Reply
  #1 (permalink)  
Old 08-08-10, 07:34 AM
Satchi Satchi is offline
New Member
 
Join Date: Aug 2010
Location: Perth, Scotland
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Unhappy Newbie help! breacrumb starting Subdirectory

hiya,

I'm so new to this and need a lot of help. I've a child site that I've built on my companys intranet - using sharepoint. However, rather than using more child sites, I've set up a page that dymanically fills based on info pulling through from a list on a custome built url

I want to set up a breadcrumb starting at my child site as Home, and then location based from there, however my URL's are based on filters like subdirectory/trade=Abbey&sector=retail or subdirectory/cover=md&sector=retail&trade=abbey etc......I want my breadcrumb to show:

Subdirectory : Abbey
or
subdirectory : Abbey : MD

Can I build a breadcrumb from the URL?

All help appreciated.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 08-09-10, 07:02 AM
Yeroon's Avatar
Yeroon Yeroon is offline
Code Master
 
Join Date: Aug 2007
Location: Netherlands, Nijmegen
Posts: 850
Thanks: 2
Thanked 20 Times in 20 Posts
Hi,

Since you posted this in the javascript forum I suppose you want a javascript solution. Maybe this will put you on the right track:

javascript Code:
  1. <html>
  2. <head>
  3.  
  4. <script>
  5.  
  6. function getQSParameter( name )
  7. {
  8.   name = name.replace(/[\[]/,"\\\&#91;").replace(/[\]]/,"\\\&#93;");
  9.   var regexS = "[\\?&]"+name+"=([^&#]*)";
  10.   var regex = new RegExp( regexS );
  11.   var results = regex.exec( window.location.href );
  12.   if( results == null )
  13.     return "";
  14.   else
  15.     return results[1];
  16. }
  17. </script>
  18.  
  19. </head>
  20.  
  21. <body>
  22. <script>document.write("<a href='your link back goes here'>" + getQSParameter('trade') + "</a> : <a href='your link back goes here'>" + getQSParameter('cover')); + "</a>"</script></a>
  23. </body>
  24. </html>
__________________
Feel free to thank people if they help you by clicking thanks at a post.
=================================
Make it idiot proof and someone will make a better idiot.
=================================
Realise the impotence of proof reading everything you publish
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks

Tags
javascript, sharepoint


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Fresh Batch of New Dedicated Servers: starting at $69/mo vortech General Advertisements 1 10-27-05 12:33 AM
Fresh Batch of New Dedicated Servers: starting at $69/mo vortech General Advertisements 0 10-18-05 02:46 PM
Fresh Batch of New Dedicated Servers: starting at $69/mo vortech General Advertisements 0 10-10-05 03:20 PM
Announcing Dedicated Server Specials: starting at $69/mo vortech General Advertisements 0 09-23-05 05:31 PM
Announcing Dedicated Server Specials: starting at $69/mo vortech General Advertisements 0 09-15-05 04:25 PM


All times are GMT -5. The time now is 10:28 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.