Posted 2012-07-21 in Guides
Have you ever wanted to add tools from SEO Scripts to a popup window or another web page? This guide shows you how to add SEO tools from your SEO Scripts powered website to an IFRAME, popup window or even a fancy lightbox modal window.
Give it a test run with the Link Analyzer tool. As you can see we get a nice, clean lightbox window that lets us use the tool without even leaving the page!
This guide requires a basic knowledge of PHP/CSS/HTML, an FTP client and text editor. If you aren't comfortable editing PHP files on your website, or just don't have the time, you can contact us to have a professional handle the customizations.
This guide requires the following:
Before getting started, always backup your website files before making any changes.
1. Create New Form View
The first step is create a new view for our tools that lets us use individual tools without displaying the full template.
In order to do this, we need to add a new layout template file, and make a few code changes to configure SEO Scripts to support the new view.
Download the new layout_form.tpl file below (right-click and "Save As"):
The file is in ZIP format, so you must first unzip the file to your computer.
Now, upload the file
Once the new layout file is uploaded to your template directory, you can make the necessary code changes.
Open the file
Find the following code (around line 41):
Directly after this line, add the following code:
Save and close the file.
Now, open the file
Directly before this line of code, add the following:
Save and close the file.
Now our view should be active. Test it out by visiting one of your tools with the new URL format, for example:
Now, whenever we add "form/" to any of our tool URLs, it shows a completely bare version of the tool!
2. Implementing an IFRAME
An IFRAME lets you embed a web page within another page. This makes it easy to add a tool to almost any other page on your website.
An IFRAME implementation would use the standard IFRAME syntax and call your tool's URL as the SRC attribute:
You can style your IFRAME with CSS. Of course, embedding a single tool in another page isn't the coolest thing we can do with this new view.
3. Implementing a Lightbox Window With GreyBox
Using the free JS popup window called GreyBox, you can load any web page or image in a slick popup modal window without leaving the page you're on.
You can follow the instructions on GreyBox to install GB on your website.
Once installed on any web site, you can just use the special URL format to load up your SEO tools with our new view:
The code above loads up the backlink checker tool in a 500x500 window in the center of the page.
4. Implementing a Classic JS Popup Window
The code example above opens up the backlink checker tool using our custom view in a 500x300 popup window. window.open() accepts several different parameters to customize the window.
That about wraps this guide up! Once you have completed this guide, you should know the steps necessary to create and implement a new view for tools in SEO Scripts.
Subscribe via RSS
Stay current with Scriptalicious news and subscribe in your favorite RSS reader.
Get the latest Scriptalicious news delivered to your inbox.
77 powerful SEO scripts for under $100.
Real-time Backlink Rank Checker script.