On 07/31/2014 08:26 AM, Huub de Beer wrote:
> Andrew Poulos wrote:
>
>> On 31/07/2014 1:04 AM, Thomas 'PointedEars' Lahn wrote:
>>> Stefan Ram wrote:
>>>
>>>> en2 <nijePravi@mail.com> writes:
>>>>> frameset. So if he makes copy of this link and passes it on new tab
>>>>> like
>>>>
>>>> Maybe something like:
>>>>
>>>> if( top.location.href.toLowerCase() === "www.example.com/cars.html" )
>>>> top.location.href = "example.com";
>>>>
>>>> . But this would only work in case that someone had enabled
>>>> JavaScript.
>>>
>>> Please don't.
>>
>> When I read a response like this from someone who knows far more about
>> coding than I do I'm unsure what the problem(s) might be. Do you not like:
>> - frames in general
>> - partial URLs
>> - frame busting protection
>> - "confusing" users by redirecting
>> - using JavaScript in this instance
>> - something else
>
> I don't know about the parent poster, but I'd advise against trying to
> restrict the user experience (through javascript). Not only can that
> frustrate the user in using your site -- if I want to open the inner frame
> in a new tab, that's my decision, not yours --, but you cannot really
> control what happens with your content once the user downloads it to their
> computer. You can add a bit of restrictive javascript and stick your head in
> the sand, but a user who wants to can easily circumvent such restrictions.
>
> If you want people to not be able to open the inner frame without the outer
> frame, you'd better look for an alternative solution without separate
> frames. For example, using a template (of the outer frame) wherein the
> contents of the inner frame are placed, will result in web pages where the
> "inner frame" and "outer frame" aren't separable. (Well, unless the user
> does do so by hand, copying out the html code of the "inner frame" into a
> separate html file; again, you don't have control over your content once it
> is downloaded by the user).
>
>>
>> Andrew Poulos
---------------------------------
The problem is quite opposite.
What i want to prevent is that someone comes to the site, chooses one
sub menu, clicks on copy links location, passes this link over mail to
some friend, and then when this friend passes this into browser, he will
get web page outside of frameset.