|
IFrames are bad stuff as far as SEO.
What I would do is add some logic to the pages that are being iframed that will check the referer. If the referrer is Google, Yahoo, etc. then do a 301 redirect (Response.Redirect will do that) to the main page with a parameter in the query string telling which page to load in the iFrame. The main page that has the menu will need to check for that param in the query string and load the iframe with that page.
After that, redesign the site to not include iFrames and use MasterPages instead.
|
|
|
|
|
Preferred solution: Don't use an iframe. Using an iframe in that way is just like using a frameset, which has exactly the same problem.
If you absolutely want to use an iframe, you have to put a Javascript on each page that checks if the page is opened in an iframe or not, and redirect to the main page if it's not. In the main page you have to add code to handle when the page redirects with the Javascript, so that you open up the correct page in the iframe.
This solution will of course not work if Javascript is disabled. Then there is no solution at all. Other than the preferred solution, of course.
---
single minded; short sighted; long gone;
|
|
|
|
|
i have a grid view with bind to a sqlDatasource
and I have a repeater that i want populate, according with the selected item in the grid view. and the data comes from a relational tables. here is the grid view and and the sqldataadapter, I know i am doing something wrong, but i dont know what it is, help please
asp:GridView ID="GridView1" <br />
runat="server" <br />
AutoGenerateColumns="False" <br />
DataKeyNames="EventId"<br />
DataSourceID="SqlDataSource1" <br />
SelectedIndex="1">
<Columns><br />
<asp:CommandField ShowSelectButton="True" /><br />
<asp:BoundField DataField="EventName" <br />
HeaderText="EventName" <br />
SortExpression="EventName" /><br />
</Columns>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:vpx_newConnectionString %>"
SelectCommand="SELECT * FROM [Events]"></asp:SqlDataSource>
and here is the the sqldataadpter
Sub BindData()<br />
'Read sample item info from XML document into a DataSet<br />
Dim cnn As SqlConnection = New SqlConnection(ConfigurationManager.ConnectionStrings("vpx_newConnectionString").ToString)<br />
cnn.Open()<br />
Dim cmd As SqlDataAdapter = New SqlDataAdapter("select * from mediaphotos Where EventID =" & GridView1.SelectedValue, cnn)<br />
<br />
Dim ds As New DataSet()<br />
cmd.Fill(ds)
-- modified at 10:13 Monday 17th September, 2007
|
|
|
|
|
I think u want to filter your data in GridView.
so for that u have to use DataView concept .
u can use dataview.filter=Expression.
MBMB
|
|
|
|
|
Thank for answering, i might be do that, thanks
|
|
|
|
|
For some reason when I have a Update Panel around a grid and try using a dataFormatString it doesn't work. My code is correct because I have used it before without an updatePanel.
DataFormatString="{0:MM-dd-yyyy}"
Any thoughts
|
|
|
|
|
Here is my example:
DateTime.UtcNow.ToString("MM-dd-yyy");
|
|
|
|
|
hi all,
i have a problem in asp.net, i have 2 folders in my application and i want to give permissions to the folders thru web.config file so that based on permissions to folders access will be given to them
can someone suggest me which section i need to use to get this functionality
Thanks
Sri
|
|
|
|
|
Use Authorization section from web.config file to aturorize to perticular users.
u can use <deny> tag to deny to perticular users.
<deny users="*">
<deny users="?">
|
|
|
|
|
Hi everybody,
i'm trying to run an asp.net(2.0) application on iis 6.0 with the rights of a specific user.
(Using the rights of the default networkservice resulted in an access violation while trying to write a file into a folder. So i've created a user with the rights i needed to write into the file system)
but now i have got another error message:
File or assembly ADODB or a dependency was not found. Access denied.
i suppose the account needs more rights to run the application with all its dependencies but how can i found out which rights do i have to grant to the account?
Or in other words which rights needs an account to run an asp.net application that uses the ADODB.dll
thanks for help
Andreas
-- modified at 15:10 Monday 17th September, 2007
|
|
|
|
|
Hi all,
<body onscroll="alert('this is sandeep')">
it is not showing any error and alert also what could be the problem
Thanks and Regards
Sandeep
If If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
Yes, it does. I've tried it in IE7 and Firefox 2, and it works just as expected.
In what situation do you experience problems?
---
single minded; short sighted; long gone;
|
|
|
|
|
Hey Guffa ya its working fine
but i want to display a menu that will change its position like this
http://www.publicjoe.co.uk/csharp1/sort05.html[^]
Just want to ask how can i get new co ordinate of left and top screen
Thanks and Regards
Sandeep
If If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
Like this:
var x, y;
var b = document.body;
var h = b.parentNode;
if (navigator.vendor && navigator.vendor.indexOf('Apple') != -1) {
x = b.scrollLeft;
y = b.scrollTop;
} else {
x = h.scrollLeft;
y = h.scrollTop;
}
(Tested in IE6, IE7, Firefox 1, Firefox 2, Netscape 8, Opera 9 and Safari 3 beta.)
---
single minded; short sighted; long gone;
|
|
|
|
|
Thanks Guffa
Sorry for late reply. I am not geting any mail notifications for the replies that's why could not able to see your answer
Thanks and Regards
Sandeep
If If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
Hi there,
Can anyone recommend the best book to learn ASP.Net 2.0 and C#.
I have been developing in these languages for a while but I need a good refresher book with good examples and easy understanding.
I need to buy myself a decent book asap.
Thanks
|
|
|
|
|
MSDN 2.0 is best one learn online or install it
Thanks and Regards
Sandeep
If If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
"but I need a good refresher book with good examples and easy understanding."
Sandeep Akhare wrote: MSDN
LOL!
MSDN is anything but "with good examples and easy understanding". It's the ultimate reference, but as bok to learn from, no.
[ My Blog] "Visual studio desperately needs some performance improvements. It is sometimes almost as slow as eclipse." - Rüdiger Klaehn "Real men use mspaint for writing code and notepad for designing graphics." - Anna-Jayne Metcalfe
|
|
|
|
|
asp.net2.0 unleased,wrox publications asp.net2.0 begining
|
|
|
|
|
i have given form authentication for my login page.
i kept all the secured pages in one folder names "Secure".
but when am trying to access the pages in Scure folder its every time redirecting me to the Login page, its not redirecting to the corresponding page.
|
|
|
|
|
|
Greetings all,
So im new to web applications.
Im trying to come up with a simple web site in which i have different levels of authentication. Let me explain:
The are some pages in my application which are free to be viewed by all. And then there are others which are confidential and hence the user need to login in order to view them.
How can i do this? do i need several web.config files placed in the various folders of my application?
thank you all
Pete.
|
|
|
|
|
|
Hi
Can any one give me code for gridview sorting. I am using dataset as datasource of gridview.
Thanks & Regards
Mishra
|
|
|
|
|