I'm trying to implement a Go to "asset #" form (Ala real estate site…"type in your property ID")
<form>
Enter the PageID <input type="text" name="PageID">
<input type="button" value="Go to the page" onclick="GoToURL();">
</form>
<script>
function GoToURL(){
location.href = "[mydomain]/?a=" + document.all.PageID.value;
}
</script>
This code launches the correct page, but applies
the design of the originating page. Is there a way around this?
[edit: the design that is applied is not the assets, but the design that is applied to the top level domain]
The design applied depends on the URL before /?a=xxx.
To if www.example.com has the home page design applied, but www.example.com/homelist (and everything under it) has the real estate design applied, change your URL to be www.example.com/homelist/?a=xxx
You can also create a dummy page which has the design applied that you want and use it:
www.example.com/home-redirect/?a=xxx
[quote]The design applied depends on the URL before /?a=xxx.
To if www.example.com has the home page design applied, but www.example.com/homelist (and everything under it) has the real estate design applied, change your URL to be www.example.com/homelist/?a=xxx
You can also create a dummy page which has the design applied that you want and use it:
www.example.com/home-redirect/?a=xxx[/quote]
Sorry Greg, we have different sites with different designs.(under the 1 domain)…and we want to be able to launch the pages from all sites…and display in their intended designs
I'm not sure if this is related, but if I put in the Asset ID of a site, the pages refreshes with [my domain]/?a="the-site-asset-id", and renders it with the unique design applied to the site…
if however i call the sites home page, one level down from the site(but with inherited design), the pages refreshes with [my domain]/?a="the-page-asset-id", the page renders with the [my domain] design.
not sure if i'm confusing myself a bit here but…the way matrix converts <a href=./a?=333> to "http: //domain/pagename …is that through javascript?
No, it is done internally when the page containing the link is saved. Matrix creates a NOTICE link to the target asset. When the page is rendered, Matrix does a regex to find internal links and replaces them with the most appropriate URL. All this is done server-side in the PHP.