Linking to a non-entrypoint GWT page - url

Is there a way in GWT to make it so that external sources can link to pages that aren't EntryPoints and have not yet been visited?
The end goal is to allow users to provide URLs to other users that link to a page that is not an EntryPoint. An example is how the GWT history feature works, where after you visit a page (such as http://<ip address>:<port>/MyEntryPointClass.html#NotEntryPointClass), even if you click to a different page and then enter that URL into the address panel, it takes you back to that page. However, if you've never visited that page before, it just takes you back to the entry point page. I have only been able to find solutions where a GWT page links to an external source, and not the other way around which is what I need.

You can use Activities and Places pattern. In your entry point class add:
historyHandler.handleCurrentHistory();
and it will take your user to the default place if no place is specified in the URL, or to the place set in the URL.

Related

How can I mask the URL path to a webpage within my website?

I have a website with a default home page of index.html, let's call the website: www.brianbauer.com ( that is my name BTW).
www.brianbauer.com operates something like a "treasure hunt". by clicking on various hot-spots on each HTML page access via brianbauer.com, you get redirected to the next html page. this continues for some period of user-clicks. One of the ideas is that on each visit, it is not obvious how the user reached a specific webpage. all they know is that they kept clicking and ended up at some final HTML page. but every click that brings up a new HTML page, still shows "http://www.brianbauer.com" in the Address bar. This is a game, nothing "wrong" going on here.
1. All of the HTML pages are owned by me, and I authored them all.
2. No illegal or unscruptulous activty of any kind going on.
3. all HTML pages in scope are under the root domain of brianbauer.com
the idea is that as users look at pictures and read a narrative, they make choices. a typical webpage might have 4 choices. depending on your choice, the next HTML page you see is determined.
I have created site maps that are basically decision trees.
think of it like a digital corn-maze. It's important that the full URL path to the current HTML page that they are looking at is masked, and should only show "www.brianbauer.com". it is true that someone more sophisticated could look at sourcecode, record their screen, keep notes, etc. but the mask will accomplish 90% of my goal.
as for being able to bookmark a certain webpage that they have "discovered"? the whole point is that they should not be able to....
I am NOT trying to mask my domain, that is easy. I am trying to simply maske what appears in the Address bar as users hit HTML pages which are children of that domain.
Thank you for the help.
Brian
There is something called CNAME cloak it might be one option.
Another option could be using ajax and replace content of the page.

Joomla - Wrong url path from google results

I have a strange problem in one Joomla website.
If i access from homepage and then navigate into the site it works correct, but if i go in some internal page from google results it shows uncorrect page layout, because the url is not correct.
This is the correct url
Correct page from homepage
and this the uncorrect url that Google finds Uncorrect page from Google
in this second page is showed rating module (that i never used) instead of an article, as you can see in links.
Someone can help me?
EDIT: I'm using Joomla 2.5 version. Every menu item is category blog type, and must show all articles of one category. Each category have 2 articles. In the uncorrect link seems that it access to single article, adding the rating that i have hidden in each article
Which version are you using?
if you can turn on SEF option in the global settings in joomla admin. Then you need to make sure all your articles are in menus. then if you link them on different pages it should keep the url the same.
The way you have it at the moment with all the x=123&... get params pages will show for what ever ids you change the menu to.
The reason you are seeing an uncorrect layout is the two different Itemid parameters (the right url has 127 while the wrong one has 104). The rest of the difference in the urls will be ignored by Joomla.
Solution: Find your menu item with id 104 (look at the menu ids on the right of the menu items view), then check which modules appear on the page from there. There may be modules in non-visible positions.
One of these modules is publishing the links with the wrong ids. If it's a Joomla core (like a search module) you can usually force the Itemid either in the module or in the component's configuration. Else you need to fixsome third party code.
Only once you have solved the multiple-itemid should you turn on SEF, otherwise you'd get the same problem only more difficult to trace.
sh404 could help you with this, I'd give it a try on a test site to see if it gets you out of trouble faster.

Using Page Anchors In Primary Site Navigation

So I have a basic (Wordpress powered) portfolio site where most of the content lives on the homepage, and then I'm using a custom posts category for the featured projects, so users can click through and get more info on the project at its category-single.php page. So the idea is it's a pretty flat site in terms of structure.
So flat, in fact, that the site navigation in the header simply links to content that is all on the home page (About, Work, What, Contact are all sections on the home page that get scrolled down to when you click).
What I want to happen is when the user is on the home page, and clicks one of the top nav links, the page scrolls down to that section (no problem here - I've got this part working just fine), and then when the user is on another page of the site (think one level deep, a custom post page) if they click the header nav links it returns them to the homepage and scrolls them down to that section. I'm thinking in terms of basic url anchor structure, like http://somesite.com/page#specific_section where that link takes the user to a specific section on somesite.com/page.
However the trouble I seem to be having is with creating these url's correctly. I've written them as mysite.com#about, mysite.com#work, mysite.com#contact, mysite.com#page-top, but instead of trigging the user to go to the homepage, the browser is interpreting those links as instructions to look for those sections on the current page.
What am I doing wrong, and what is the correct way to accomplish this?
The thing I'm trying to consider additionally, is whether I need to create PHP logic that displays the links one way on the homepage, and another way on the rest of the site.
What you need to do is use the actual filenames of the pages in question, like:
mysite.com/aboutme.html#qualifications
`mysite.com/portfolio.html#ZirTech
For links to the homepage, try either using the root relative path or fully qualifying the link like so:
http://www.mysite.com/#section fully qualified
/#section relative path
You shouldn't need to implement them a different way on the homepage - just implement them properly throughout the site.
When you write the URLs as mysite.com#work, mysite.com#contact, mysite.com#page-top the browser looks for the page in question, because it is not instructed to go to another page (you need to add "/" to redirect it).
If you want them to point to the main page, set them as
mysite.com/index.php#work, mysite.com/index.php#contact, mysite.com/index.php#page-top
Maybe it is possible without index.php, but I'm a bit lazy to test now:
mysite.com/#work, mysite.com/#contact, mysite.com/#page-top

Linking to a specific section of a page from Google custom search engine result

I would like to know if there is a way when using Google custom search engine to have Google CSE link to a page with a URL like this
http://www.mysite.com/mysection/mysectionarticles.html#myarticle234
or something close to that.
Let’s say Google would find the searched words in a certain part of the page it could be in a or after an anchor or something like that and would supply in the search result a way to link to this specific section of the page.
So if you have big pages the user wouldn't have to scroll through the page to find the relevant part he saw in the CSE snippet.
It could also be used if you have a dynamic page that change state using JavaScript. Part of the page is hidden to the user until he does an action in the pages, but this hidden content was indexed by Google because it’s part of the page. So when the user clicks on the link in the search result he ends up on a page and can’t find the relevant part because it’s hidden.
Take a look at Google's support for structured/rich data and ajax urls for crawling (aka hash-bangs). One or both of them ought give you access to the pages with the right things displayed.

Is there a way to find all the pages' link by a URL?

If I have a link say http://yahoo.com/ so can I get the links inside yahoo? For example, I have a website http://umair.com/ and I know there are just 5 pages Home, About, Portfolio, FAQ, Contact so can I get links as follows programmatically?
http://umair.com/index.html
http://umair.com/about.html
http://umair.com/portfolio.html
http://umair.com/faq.html
http://umair.com/contact.html
Define what you mean by "links inside yahoo".
Do you mean all pages for which there is a link to on the page returned by "http://www.yahoo.com"? If so, you could read the HTML returned by an HTTP GET request, and parse through it looking for <a> elements. You could use the "HTML Agility Pack" for help.
If you mean, "All pages on the server at that domain", probably not. Most websites define a default page which you get when you don't explicitly request one. (for example, requesting http://umair.com almost certainly returns http://umair.com/index.html). Very few website don't define a default, and they will return a list of files.
If you mean, "All pages on the server at that domain, even if they define a default page", no that cannot be done. It would be an extreme breach of security.
This could be done by a Web Crawler, read some basic information about it:
http://en.wikipedia.org/wiki/Web_crawler
Includes Open Source crawlers, see if any of them is what you are looking for.

Resources