add cf worker code link for redirection

This commit is contained in:
James Feng Cao 2024-12-11 19:15:03 +08:00
commit 01572990b7
10 changed files with 25 additions and 19 deletions

View file

@ -6,7 +6,7 @@
<description>Recent content in _Posts on uweb browser: unlimited power</description>
<generator>Hugo</generator>
<language>en</language>
<lastBuildDate>Tue, 10 Dec 2024 11:31:33 +0800</lastBuildDate>
<lastBuildDate>Wed, 11 Dec 2024 19:12:24 +0800</lastBuildDate>
<atom:link href="/en/_posts/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>CSS styles</title>
@ -48,7 +48,7 @@
<link>/en/redirect/</link>
<pubDate>Tue, 11 Apr 2023 00:00:00 +0000</pubDate>
<guid>/en/redirect/</guid>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the options with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the option with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
</item>
<item>
<title>Hosts files</title>

View file

@ -6,7 +6,7 @@
<description>Recent content on uweb browser: unlimited power</description>
<generator>Hugo</generator>
<language>en</language>
<lastBuildDate>Wed, 11 Dec 2024 16:00:41 +0800</lastBuildDate>
<lastBuildDate>Wed, 11 Dec 2024 19:12:24 +0800</lastBuildDate>
<atom:link href="/en/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>Search engine query URLs</title>
@ -62,7 +62,7 @@
<link>/en/redirect/</link>
<pubDate>Tue, 11 Apr 2023 00:00:00 +0000</pubDate>
<guid>/en/redirect/</guid>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the options with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the option with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
</item>
<item>
<title>Hosts files</title>

View file

@ -105,7 +105,7 @@
</div>
<p>Last Modified: 11 December 2024<br>
echo -n to echo without newline<br>
add cf worker code link for redirection<br>
<pre></pre>
</p>

View file

@ -49,7 +49,7 @@
<li><a href="../tags/redirection/index.html#">redirection</a> </li>
</ul>
<p>⚠️<span style="color:red">Redirection forwards cookies</span> with the setting option &quot;Redirect cookies&quot; enabled, so use the options with care.</p>
<p>⚠️<span style="color:red">Redirection forwards cookies</span> with the setting option &quot;Redirect cookies&quot; enabled, so use the option with care.</p>
<h4 id="setting-options-url-redirection-vs-resource-redirection">Setting options: &quot;Url redirection&quot; vs. &quot;Resource redirection&quot;</h4>
<p>&quot;Url redirection&quot; redirects the main/page url only while &quot;Resource redirection&quot; is for all urls in the page.</p>
<h4 id="global-redirection">Global redirection</h4>
@ -63,6 +63,8 @@
<p>(to provide more options to users) If the global redirection url does not end with '/', '?' or '=', it means the global redirection url is naked. then the resource is fetched with by the url &quot;[global redirection url] + '/'+ [scheme]+ '/' + [url without scheme]&quot;. For example, when the global redirection url is &quot;https://domain.com/pathXXX&quot;, the real url to visit &quot;https://cnn.com&quot; is &quot;https://domain.com/pathXXX/https/cnn.com&quot;.</p>
</li>
</ul>
<p>Example: &quot;https://muweb.pages.dev/redirect?&quot;</p>
<p><a href="searchurl/cloudflare/redirect.js">global redirection code for cloudflare workers</a> free deployment: The global redirection url is &quot;https://subdomain.workers.dev/&quot;, which is just the worker's domain name.</p>
<h4 id="defaultredirect-valid-only-without-global-redirection-url">&quot;default.redirect&quot; (valid only without global redirection url)</h4>
<p>Click the following links to append mirrors to the file &quot;default.redirect&quot;:<br>
<a target="_self" href="i:0gdefault.redirect:../../zh/searchurl/txt/redirect.cfg">google recaptcha mirror</a></p>
@ -77,8 +79,8 @@
</ul>
</div>
<p>Last Modified: 7 April 2024<br>
more details on global redirection url<br>
<p>Last Modified: 11 December 2024<br>
add cf worker code link for redirection<br>
<pre></pre>
</p>

View file

@ -29,7 +29,7 @@
/>
</url><url>
<loc>/en/</loc>
<lastmod>2024-12-11T16:00:41+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
<xhtml:link
rel="alternate"
hreflang="zh"
@ -42,7 +42,7 @@
/>
</url><url>
<loc>/en/_posts/</loc>
<lastmod>2024-12-10T11:31:33+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
<xhtml:link
rel="alternate"
hreflang="zh"
@ -90,7 +90,7 @@
/>
</url><url>
<loc>/en/tags/</loc>
<lastmod>2024-06-11T08:12:27+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
<xhtml:link
rel="alternate"
hreflang="zh"
@ -181,10 +181,10 @@
/>
</url><url>
<loc>/en/tags/redirection/</loc>
<lastmod>2024-04-07T20:48:24+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
</url><url>
<loc>/en/redirect/</loc>
<lastmod>2024-04-07T20:48:24+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
<xhtml:link
rel="alternate"
hreflang="zh"

View file

@ -6,7 +6,7 @@
<description>Recent content in Tags on uweb browser: unlimited power</description>
<generator>Hugo</generator>
<language>en</language>
<lastBuildDate>Tue, 11 Jun 2024 08:12:27 +0800</lastBuildDate>
<lastBuildDate>Wed, 11 Dec 2024 19:12:24 +0800</lastBuildDate>
<atom:link href="/en/tags/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>Clipboard</title>

View file

@ -6,14 +6,14 @@
<description>Recent content in Redirection on uweb browser: unlimited power</description>
<generator>Hugo</generator>
<language>en</language>
<lastBuildDate>Sun, 07 Apr 2024 20:48:24 +0800</lastBuildDate>
<lastBuildDate>Wed, 11 Dec 2024 19:12:24 +0800</lastBuildDate>
<atom:link href="/en/tags/redirection/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>Resource redirection</title>
<link>/en/redirect/</link>
<pubDate>Tue, 11 Apr 2023 00:00:00 +0000</pubDate>
<guid>/en/redirect/</guid>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the options with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
<description>&lt;p&gt;⚠️&lt;span style=&#34;color:red&#34;&gt;Redirection forwards cookies&lt;/span&gt; with the setting option &amp;quot;Redirect cookies&amp;quot; enabled, so use the option with care.&lt;/p&gt;&#xA;&lt;h4 id=&#34;setting-options-url-redirection-vs-resource-redirection&#34;&gt;Setting options: &amp;quot;Url redirection&amp;quot; vs. &amp;quot;Resource redirection&amp;quot;&lt;/h4&gt;&#xA;&lt;p&gt;&amp;quot;Url redirection&amp;quot; redirects the main/page url only while &amp;quot;Resource redirection&amp;quot; is for all urls in the page.&lt;/p&gt;&#xA;&lt;h4 id=&#34;global-redirection&#34;&gt;Global redirection&lt;/h4&gt;&#xA;&lt;p&gt;&lt;a href=&#34;i:60/data/data/info.torapp.uweb/files/config.html:https://jamesfengcao.codeberg.page/en/searchurl/config.html&#34;&gt;Global redirection&lt;/a&gt; is enabled with the setting option &amp;quot;Resource redirection&amp;quot; or both &amp;quot;Url redirection&amp;quot; and &amp;quot;Redirect cookies&amp;quot;.&lt;/p&gt;&#xA;&lt;p&gt;When a valid global redirection url is set, the &amp;quot;default.redirect&amp;quot; has no effect, and any url resource is fetched with the new url by appending the original url to the global redirection url.&lt;/p&gt;</description>
</item>
</channel>
</rss>

View file

@ -3,7 +3,7 @@ title: Resource redirection
date: 2023-04-11
tags: [redirection]
---
⚠️<span style="color:red">Redirection forwards cookies</span> with the setting option "Redirect cookies" enabled, so use the options with care.
⚠️<span style="color:red">Redirection forwards cookies</span> with the setting option "Redirect cookies" enabled, so use the option with care.
#### Setting options: "Url redirection" vs. "Resource redirection"
"Url redirection" redirects the main/page url only while "Resource redirection" is for all urls in the page.
@ -17,6 +17,10 @@ When a valid global redirection url is set, the "default.redirect" has no effect
- (to provide more options to users) If the global redirection url does not end with '/', '?' or '=', it means the global redirection url is naked. then the resource is fetched with by the url "[global redirection url] + '/'+ [scheme]+ '/' + [url without scheme]". For example, when the global redirection url is "https://domain.com/pathXXX", the real url to visit "https://cnn.com" is "https://domain.com/pathXXX/https/cnn.com".
Example: "https://muweb.pages.dev/redirect?"
[global redirection code for cloudflare workers](searchurl/cloudflare/redirect.js) free deployment: The global redirection url is "https://subdomain.workers.dev/", which is just the worker's domain name.
#### "default.redirect" (valid only without global redirection url)
Click the following links to append mirrors to the file "default.redirect":
<a target="_self" href="i:0gdefault.redirect:../../zh/searchurl/txt/redirect.cfg">google recaptcha mirror</a>

View file

@ -4,7 +4,7 @@
<sitemap>
<loc>/en/sitemap.xml</loc>
<lastmod>2024-12-11T16:00:41+08:00</lastmod>
<lastmod>2024-12-11T19:12:24+08:00</lastmod>
</sitemap>

View file

@ -96,7 +96,7 @@ html/text/html: 选中富文本为html格式, 输出mimetype为text/html。<br>
</div>
<p>Last Modified: 11 December 2024<br>
echo -n to echo without newline<br>
add cf worker code link for redirection<br>
<pre></pre>
</p>