Add a WORKING Paypal button to a 2013 365 public site

101313_1928_addaworking1It’s well known that Paypal buttons don’t work on 2013 public sites. A basic html rule doesn’t allow forms to be nested so you can’t add the required PP form tag within the aspnetForm page tag. If you wrap the PP code in
/form> …. your code here…. form>

tags they will work in Firefox/Chrome but not in IE.Oy vay! So here’s yet another “no code” workaround or 2 to compensate for the sloppy coding behind the public site editor.
Method 1: Buy Now Buttons.
If you only need a Buy Now (or simple Add To Cart) button you can use the email link Paypal provides.
Create your button at Paypal
In the last step, click the email tab and copy the link
Add some text or an image to a site page. You can grab the Paypal image url from another button.
Highlight the text/image and insert a link
Select “from address” and paste in the PP link copied earlier.
There’s an example at the top of this page »

Method 2: Add To Cart And Buttons With Options

First, paste your Paypal code into notepad (as many button codes as you need).
Save the file as an .aspx file
Upload it to the SITE ASSETS library in the public site (TIP:or create file directly in Sharepoint Designer).
Insert a Page Viewer web part on your page
Open the page viewer’s web part properties
Enter the url of your uploaded file as the target link

101313_1928_addaworking2The page viewer web part includes a space for the title even if you leave the title box blank. If you want to eliminate the “gap”, simply open the web part properties box and select “none” under appearance » chrome type.
You can see examples of this procedure here »
Why do I have to use a page viewer web part?
The page viewer wp iframes the paypal aspx “page” on your public site page. The iframe isolates the paypal code from the form tags that wrap all content on the public site page and allows it to work correctly.
Questions?
This issue existed in Office Live Small Business and it’s bizarre that such a simple thing to fix hasn’t been addressed in O365. I can’t explain that, but if you have any questions about this workaround, please ask them in my forum ». For development work, you can contact me here ». Click a social button up top to share this post if you found it useful!

Change logo size – Office 365 Sharepoint 2013 public site

Your logo represents your brand and is arguably the most important single element on your site. Most competent web site platforms recognize that and provide tools to ensure your logo looks as good as it can. Because Office 365 isn’t really designed with public sites in mind, it only gives you one sizing option. If your logo doesn’t fit, there’s no editing tool to change that. To resize your logo – or any image – normally you could just add some custom css to the image. The containing element should then expand to accommodate the image. Due to poor coding practices in 365 though, only the width can be changed this way. MSFT has restricted the height of the containing element which may throw off your logo’s proportions.To override that , use the”min-height” attribute in your css (add this to your custom stylesheet – changing the dimensions to suit):.ms-siteicon-img, #DeltaSiteLogo{width:200px;min-height:150px !important}
OR try:
.ms-siteicon-img{min-height:150px} /*the logo image*/
div#siteIcon{height:150px !important}/*the containing element*/
The latter will also make the header area larger and resposition the tilte and nav, which may not be desirable. If so, try this:
.ms-siteicon-img{min-height:150px;z-index:100;position:relative;top:-50px !important}
That will enlarge the logo AND keep it layered above the header without repositioning the title/nav elements.

If the width is an issue try “min-width” too. This works in all browsers that support the min- attribute (so won’t work in IE6 and IE7)

Questions?

Visit my forum » if you have any questions. For development work, you can contact me here ». And if you think this would be useful to others, feel free to share it by clicking one of the share buttons up top!

Change your public site’s home page (2010/2013)

For some unknown reason, the ability to change a Sharepoint site’s home page is available in the site settings for team sites (Look and feel»Welcome), but hidden forpublic sites. If you don’t want to fire up Sharepoint Designer to do it, here’s an easier way using the ui:Appendthis to your public site’s domain:
2010:/_layouts/AreaWelcomePage.aspx
2013:/_layouts/15/AreaWelcomePage.aspx
So, in my case it would be:
365.webbrewers.com/_layouts/AreaWelcomePage.aspx

Once there, simply change the url to your desired page.

This seems to work for both 2010 and 2013 Small Business and Enterprise accounts.

UPDATE:Hmmm, it seems this has now been changed and both Ent and Sm Bus public site settings now include the ability to change the “Welcome” (ie home) page. Go to site settings»Look and feel»Welcome page.

Edit An Office 365 Sharepoint Online 2013 Public Site Master Page: Change The Favicon

060813_1920_edita2013pu1Here’s one way to change the favicon for your 2013 public site by editing a master page. The same technique can also be used to edit other elements.Create A Favicon.
First upload a favicon image to an anonymously accessible library (the 2010 image lib or 2013 site assets lib should work).
A favicon can be any image but should be square: 16 x 16 or 32 x 32 would be ideal. It should also be saved as favicon.ico – rename it if you use a jpg or png.
TIP: Some browsers (notably IE) may not show the image if it isn’t converted to an ico file at a site like: http://www.favicon.cc/

Adjust the Master Page.

Open the public site’s settings: domain.com/_layouts/15/settings.aspx
Download the desired master page from web designer galleries»master page and page layouts

060813_1934_edita2013pu2

 

 

RENAME the file to say”oslo1.master” (important!)
Open it in notepad or other text editor and change the image url in this line to your favicon’s url – it’s somewhere around line 21 in the Oslo master page: SharePoint:SPShortcutIcon runat=”server” IconUrl=”domain.com/siteimages/favicon.ico”

060813_1946_edita2013pu3

 

Deploy The Master Page.

Upload it back to the gallery and publish it
In settings go to Look and feel»master page
Select your new master from the 2 drop downs.

060813_1935_edita2013pu4

Using Sharepoint Designer
If you’re comfortable with SPD, you can avoid the download routine and edit the html master page directly. Just open the site in SPd and go to all files » catalogs » master pages and look for the correct html master to edit.

An example of the effect can be seen here: http://365new.webbrewers.com/

Questions?
Visit my forum » if you have any questions. For development work, you can contact me here ». And if you think this would be useful to others, feel free to share it by clicking one of the share buttons up top!

Use separate sub domains (or domains) for BOTH your 365 public sites!

When your 2010 Office 365 account is converted to 2013, you end up with 2 public web sites. Officially, you can only assign a personal domain to one of the sites but in reality it’s quite easy with an Enterprise account to use a different personal domain for each site. I specifically cover adding sub domains here, but the same process applies to domains with a few adjustments.As noted, this only works with Enterprise accounts and would be different – if even possible at all – for a P account. For small business accounts the workaround would be to url forward one of the domains to the least important site.”Look Ma, 2 web sites with 2 separate domains!”

062213_0249_useseparate1

To see what I mean click here:http://365.webbrewers.com/Pages/webbrewerstest2.aspx
For a 2013 site see: http://365new.webbrewers.com
Both sites are in the same 365 account, but use different sub domains.

Instructions – set up in Sharepoint
If the parent domain is already verified, a sub domain will automatically verify. To verify a new sub domain, in 365 go to: Admin»Domains»Add a domain.
Step 1:
Enter your full sub domain (eg 365.domain.com)
Get the TXT record
Enter it at your domain host in the dns zone record section
Wait a few minutes and then click”Verify”
NOTE:If you have 2 public sites, apparently you have to enter the prefix for the sub domain as the host for the 2nd site, not the normal @ symbol.

Step2:
Once it’s verified, add any users you need

Step 3:
Select”Sharepoint” as the domain intent.

Go to the Sharepoint admin center, select the desired site and choose the sub domain from the drop down. When I did that I got a strange “Deleted” note by the default site name, but nothing was deleted and the site still worked under either the sub domain or the original default domain. MSFT couldn’t tell me what the “deleted” referred to!

Instructions – connect your domain
Next, you’ll point the sub domain at your 365 public site by adding an A record at your domain host.

Open a cmd screen and type in”ping your365domain-web.sharepoint.com” (without the quote marks and use the default domain, normally domain-web.sharepoint.com for 2010 sites, domain-public.sharepoint.com for 2013 sites).
Copy or note the ip address – it will be something like 157.55.62.110.
Go back to your domain host’s dns zone record application.
Add an A record and enter the sub part of the sub domain as the host and the ip address as the target. For a domain, use @ in the host field.:
HOST POINTS TO TTL
365 157.55.62.110 600 seconds (or 1 hr etc) For sub domains
@ 157.55.62.110 600 seconds (or 1 hr etc) For domains

Save the zone file and within 15 minutes or so, your site should start coming up under the sub domain.
Example:http://365.webbrewers.com
Why does MSFT tell me to use a CNAME instead of an A Record?
MSFT’s instructions tell you to use a CNAME entry with the host set at “www”. A CNAME is like an alias, so requests for www.domain.com are going to be sent to the server hosting domain.com to look for a site called “www.domain.com”. That works if you only want the site to be found with a www request, or if all your sites are on the same host. If you use an A record, the request will be sent to whatever server the ip address entered represents. In other words, your site will be found with or without the www and you can use your domain with a site hosted in one place, and sub domains with your O365 site or vice versa. In my case, webbrewers.com is a WordPress site hosted outside of 365, and the 2 sub domains point to the 2 365 public sites.
Personally, I think it’s a better arrangement.