Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Tabs / Layers within SharePoint Wiki page

Posted on 2010-11-16
9
Medium Priority
?
1,265 Views
Last Modified: 2012-05-10
I have a site page that I want to add tabbed sections to but for some reason I am not able to get it to save the javascript and css needed to make this happen.  Is there a way to link to js and css files from within a wiki page and how would I go about adding custom code to a wiki page without it overwriting when I save the source?

If you know of an easier way to provide a tabbed user interface for my users I would be interested also.  I have looked at EasyTab but it seems to only work on web part pages and I would rather use wiki pages if possible.  

Below is a link to the script/css I like for now if helps since this is what I would like to use within the page:

http://www.barelyfitz.com/projects/tabber/
0
Comment
Question by:JoMar
  • 5
  • 3
9 Comments
 
LVL 15

Expert Comment

by:dp_expert
ID: 34154307
What version of SharePoint you are using? In 2007 you are able to add a web part to a wiki page - simply click on the "Edit page" in the site actions menu. What do you mean by "I;m not able to get it to save"? Where do you input the javascript and CSS? On the wiki content? Did you try using the SharePoint designer?

One thing you need to remember is that changes you do with SPD or browser affect only current Wiki Page, not all pages. Each wiki page has it's own web part page. If you would like to modify all wiki pages you would need to modify the page in the 12 hive.
0
 
LVL 21

Expert Comment

by:chapmanjw
ID: 34155243
When you are working with SharePoint Wiki pages, you cannot add JS to the "wiki" content itself.  However, when you are on the Wiki page, instead of hitting Edit to edit the Wiki content, goto Site Actions > Edit Page.  Each Wiki page is actually a web part page.  You can add a Content Editor Web Part to the page and edit the source of the CEWP to add your JS, CSS, and other markup.
0
 

Author Comment

by:JoMar
ID: 34156153
We are on SharePoint 2010.  When I added the CEWP did not seem to work but I will try again and verify what I am seeing but seemed that the content really only affected the part and would not show for the other content on the wiki page.  When I edit the source of the wiki page my css or javascript is removed or things like the following are added to it so that it will not function:

.ExternalClassE188A71C513045AABFD0FD5E9F7522B3 H2 {
      PADDING-BOTTOM: 20px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT: bold 14px Verdana, Arial, Helvetica, sans-serif; COLOR: #000; PADDING-TOP: 0px
}

The bold section is added to every line of the <style> tag added.  

My main goal is being able to use the code from the below link to provide tabs on the page to divide up some of the content for the users.  I would rather not use web part pages if I dont have to but if that is the only option may not have a choice.  Know I am missing something simple and any help is appreciated.  

0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:JoMar
ID: 34156166
0
 

Author Comment

by:JoMar
ID: 34164646
Any ideas on this?
0
 
LVL 15

Expert Comment

by:dp_expert
ID: 34167911
Sharepoint 2010 tends to modify the HTML - adds unique identifiers and so on. I would recommend  using the SharePoint Designer - it'll give you more control.
0
 

Author Comment

by:JoMar
ID: 34174432
Unfortunatly when using SPD it does similar to any CSS or JavaScript added within the content area.  My only idea would be having to create a custom master page just for this site even though it does not affect the over all look.
0
 

Author Comment

by:JoMar
ID: 34183914
Is there a way to attach css or js files to the page w/out editing the master page?  
0
 
LVL 15

Accepted Solution

by:
dp_expert earned 2000 total points
ID: 34186002
Hello
Yes - do not add the HTML into a web part - add your code outside the Web Part zones. You can also detach the page from master page and edit entire page content.
0

Featured Post

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

Question has a verified solution.

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

There is one common problem that all we SharePoint developers share: custom solution deployment. This topic can't be covered fully in this short article, so all I want to do in this one is to review it from a development-to-operations perspectiv…
For SharePoint sites, particularly public-facing ones, there are times when adding JavaScript, Meta Tags, CSS Styles or other content to the page <head> section is more practical than modifying master pages.  For instance, you could add the jQuery l…
This Micro Tutorial will teach you how to add a cinematic look to any film or video out there. There are very few simple steps that you will follow to do so. This will be demonstrated using Adobe Premiere Pro CS6.
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
Suggested Courses
Course of the Month6 days, 9 hours left to enroll

783 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