Solved

I need an iFrame alternative

Posted on 2009-05-06
13
2,005 Views
Last Modified: 2013-11-19
I need an alternate to iframe for many reasons. I want to pull  in page(s) that already resides on my site.

Currently using but would like to avoid:

<iframe src ="/rating/irating.asp?ID=TEST1" name="TEST1" width="300" height="300">
  <p>Your browser does not support iframes.</p>
</iframe>

I tried using AJAX INCLUDE script that I got off Dynamic Drive but it didn't work the way I needed it to. It needs to also include a unique name: name="something"

<script type="text/javascript">
ajaxinclude("/rating/irating.asp?ID=TESTAGAIN1")
</script>
0
Comment
Question by:swaggerking
[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
  • 5
  • 4
  • 3
13 Comments
 
LVL 17

Expert Comment

by:OriNetworks
ID: 24322058
Would it work for you if you included the pages on the server side such as an ASP Include?
0
 

Author Comment

by:swaggerking
ID: 24327063
I wish. Unfortunately for this instance it won't work. I'm trying to implement an ASP Star Rating script into my web pages. I'm using the example provided by http://www.chrishardy.co.uk/asp/scripts/accessible-star-ratings/.

The rating system works great for a single page with single object. I 'm trying to rate more than one object on a page. For this they state:

"You can create as many of these as you need, as long as the IFrame name value and the ID parameter are unique for each IFrame section. As you can see below, the ID parameter (and even the name) can be defined dynamically via ASP."

There iframe example:
<iframe src ="/rating/irating.asp?ID=UniqueID" name="UniqueID" width="300" height="300">
  <p>Your browser does not support iframes.</p>
</iframe>


0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 24333772
But what is the issue?

Add the name...
<iframe src ="/rating/irating.asp?ID=<%= someAspVar %>" name="<%= someAspVar %>" width="300" height="300">
  <p>Your browser does not support iframes.</p>
</iframe>



0
Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

 

Author Comment

by:swaggerking
ID: 24336599
The issue: I Some browsers may see iframes as a security risk dependent upon their settings, iframes are not allowed in strict doctype, display of iframe in ie 6/7 is undesirable, and so on.

I was just hoping that some one out there might know of another technique that I could use instead of inserting iframes into my pages.


0
 
LVL 17

Assisted Solution

by:OriNetworks
OriNetworks earned 75 total points
ID: 24336988
I would suggest going with something based of of AJAX which is can basically be put on the same page and it can send information back to the server (called a postback) without having to reload the page. THere are a few examples out there but here is a quick one i found when googling for ajax star rating system.
http://masugadesign.com/the-lab/scripts/unobtrusive-ajax-star-rating-bar/
0
 

Author Comment

by:swaggerking
ID: 24357624
I was able to find a solution on my own.
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 24361382
Please share
0
 

Author Comment

by:swaggerking
ID: 24375760
mplungian,
I never found an alternative to iframes that I was totally happy with. Ended up having a developer buddy come over and shared with me his ajax star rating script. Something very similar to http://www.ex-designz.net/softwaredetail.asp?fid=1206 and to what OriNetworks mentioned, but in asp.
0
 
LVL 17

Expert Comment

by:OriNetworks
ID: 24380882
So if AJAX was the solution, why would my suggestion of going with an AJAX based soluition not be marked as the solution?
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 24382139
Perhaps because that was a suggestion and the asker already was aware of the existence of Ajax.
He did not choose your suggested example because it was in PHP
0
 

Accepted Solution

by:
swaggerking earned 0 total points
ID: 24386285
OriNetworks,
By no means did I wish to diminish your suggestion. This site is worth every penny and you guys (the true experts) have helped me numerous times. The only reason I didn't choose your suggestion is pretty much on par with mplunjan comments. In addition, I had already implemented the switch to ajax with the help of friend and was testing it prior to receiving your php suggestion and closing the ticket.
0
 
LVL 17

Expert Comment

by:OriNetworks
ID: 24391183
No problem.
0

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

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

I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. 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.: (CODE)
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

726 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