mirror of
https://github.com/neocities/neocities.git
synced 2025-04-25 01:32:36 +02:00
config.yml.template update and surfinject
This commit is contained in:
parent
169a741213
commit
2e76bc9a0b
2 changed files with 11 additions and 0 deletions
|
@ -13,6 +13,7 @@ development:
|
|||
email_unsubscribe_token: 'somethingrandom'
|
||||
surf_proxy_uri: 'http://surf.somedomain.local:9292' # May want to use dnsmasq instead of /etc/hosts here
|
||||
surf_iframe_source: 'http://127.0.0.1:9292'
|
||||
logs_path: /path/to/nginx/logs
|
||||
test:
|
||||
database: 'postgres://neocities@localhost/neocities_test'
|
||||
database_pool: 1
|
||||
|
|
10
public/js/surfinject.js
Normal file
10
public/js/surfinject.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
<script>
|
||||
function _nc_surf_page_overload() {
|
||||
var ele = document.getElementsByTagName('a')
|
||||
for(var i=0; i<ele.length; i++) {
|
||||
if(ele[i].href.match(/^\w+:\/\//i) && !ele[i].href.match(/^.+\.neocities\.org/i))
|
||||
ele[i].setAttribute('target', '_blank')
|
||||
}
|
||||
}
|
||||
_nc_surf_page_overload()
|
||||
</script>
|
Loading…
Add table
Reference in a new issue