When i use the "Change affiliate publishing options" the affiliate settings change but urls are not rewritten to the new url.
example: a node is published to:
- all affiliates
- sub1.domain.com
- sub2.domain.com
changing it to:
- sub2.domain.com
still lets the urls point to sub1.domain.com
MySQL 4.1.22
PHP 4.4.8
PHP register globals off
Apache/1.3.34 Ben-SSL/1.55
editing (clicking the edit tab) and submitting that node with no changes makes it work.
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | Picture 1.png | 38.57 KB | agentrickard |
| #11 | Picture 3.png | 29.69 KB | agentrickard |
| #5 | Picture 1.png | 45.13 KB | agentrickard |
Comments
Comment #1
agentrickardYou're talking about the batch editing screen provided by Domain Content, right?
The URLs are not rewritten on the content editing screen or on all pages?
Do you have the strict SEO setting turned on?
Comment #2
agentrickardHave you installed the _new_ version of the URL rewrite sequence and the patch that goes with it?
Comment #3
derjochenmeyer commentedyes and i installed the _new_ version, but i get the same behaviour with both the old and the new way...
new setup:
- i copied the custom_url_rewrite_outbound() function to the end of settings.php
- removed the old common.inc patch and applied the new one...
- SEO settings enabled...
im not talking about the urls on the batch editing screen, but links on my frontpage for registered and anonymous users...
Comment #4
agentrickardThat is odd. Do you have a URL?
We are talking about links in the main content area, not blocks, correct?
There must be something missing in the configuration.
Are there any warnings at the top of Admin > Bulld > Domains ?
Comment #5
agentrickardOh, when you use the bulk update form, you must explicitly select the 'change affiliate publishing options' action. If you do not, the affiliate settings will not be processed. This is by design.
Comment #6
derjochenmeyer commentedhttp://routebook.com/
the block on the right called "Routenkommentare" (comments)
right now the site uses only one subdomain http://tirol.routebook.com/
since i dont have any clue what i could do i manually edit and submit each node for which a new comment is published
Comment #7
derjochenmeyer commentedquestion, if i want to write a script that updates "node relativity" related nodes with the affiliate publishing settings of a parent what do i have to update
domain_access SET (nid, realm, gid)
is that all to the url rewrite to work? there is probably an api function? since im working mobile right now i had chance to check the docs...
Comment #8
agentrickardAnd those links are not going to the correct domain? Right now, they all point to http://tirol.routebook.com/
Are you using block cache? Page cache?
Comment #9
agentrickardWhich module is generating that block?
Comment #10
derjochenmeyer commentedNo Cache. The links are now pointing to the right domain, because i fixed them by editing and submitting each node.
The Block is generated by a custon module/query...
SELECT
n.nid,
n.title,
comments.uid,
comments.cid,
comments.subject,
comments.timestamp,
users.name,
content_type_route.field_routenschwierigkeit_value
FROM {node} n
INNER JOIN content_type_route ON content_type_route.nid = n.nid
INNER JOIN comments ON comments.nid = n.nid
LEFT JOIN users ON users.uid = comments.uid
WHERE n.type = 'route' AND n.status = 1
ORDER BY comments.timestamp DESC LIMIT 10
while ($comment = db_fetch_object($query)) {
$title = l($comment->subject, "node/".$comment->nid);
print $title;
}
Comment #11
agentrickardI tested a variant of your block successfully -- editing the parent node both through node/*/edit and the batch handler. Using code:
Now, the query is slightly different, but that isn't relevant.
I think there is a settings issue somewhere. There are three ways to force links to go to different domains:
1) For search request results. That is not relevant here.
2) For specific page requests (such as 'user/*/track' or 'blog/*') as defined by "Special Page Requests."
3) By turning on Search Engine Optimization -- set it to 'Rewrite all URLs to point to a single source'
In these cases, url paths are matched against the list in "Node Link Patterns." The defaut patterns are:
Here is the issue with blocks.
1) Since they are not page requests, rule #2 does not apply to them -- unless the blocks only appear on specific pages that are mapped to the "Special Page Requests" link.
2) You must enable SEO strict in order to ensure that block links are always rewritten.
And there is another complication that may affect you. The logic inside of the URL rewrite makes the following assumption:
-- If the node is assigned to "all affiliates" then the rewritten link will always point to the main domain.
-- If the node is assigned to more than one affiliate, it will take the first match, based on domain creation order.
So this may also be the problem.
You can (as of 1.0) use the Domain Source module to specify exactly which domain you want to use when rewriting links for each node.
Attached are some shots of my configuration.
Comment #12
agentrickardNote that if you wrap the above query in
db_rewrite_sql(), it should only return comments that are visible on the active domain, and then this issue goes away, since the links do not need to be rewritten.Comment #13
agentrickardDomain Source, by the way, integrates with Domain Content to allow batch assignment of source domains.
Comment #14
derjochenmeyer commentedthanks for the detailed answers!!! Ill test what works for me.
Right now my parent nodes are only published to one domain.
Comment #15
agentrickardSomething occurs to me that might also work. If you have strict SEO turned off, in your block, try this.
In theory, this would temporarily enable domain rewrite rules inside you block.
Comment #16
agentrickardComment #17
summit commentedBookmarking, greetings, Martijn