Current time: 11-27-2024, 12:55 AM Hello There, Guest! (LoginRegister)


Post Reply 
Domain Disabled message howto?
Author Message
xokaido Offline
Newbie
*

Posts: 7
Joined: Dec 2008
Reputation: 0
Post: #1
Domain Disabled message howto?
Hello all...
I have a question:
I want to be able to show error message indicating
that domain (the client is on) is disabled...
I have seen some ISPCP Omega customers did this and want to
do it but don't know how...
is it possible to show my Error file when domain is disabled?...
Thank you in advance... :-)
12-29-2008 02:59 AM
Find all posts by this user Quote this message in a reply
xokaido Offline
Newbie
*

Posts: 7
Joined: Dec 2008
Reputation: 0
Post: #2
RE: Domain Disabled message howto?
Here I wrote little bash script for that purpose... can share if anyone needs:
Quote:#!/bin/bash

DOM_DIR=/var/www/virtual # directory where all domains go
DOMAINS="`ls $DOM_DIR`" # domains we have
MOVED="`ls $DOM_DIR/suspend | grep -v 'htdocs'`" # directory where we would link for message
# this dir also should contain 'htdocs' subdir
for dom in $DOMAINS
do
if [ ${dom##*.} == "disabled" ] # if we have disabled domain...
then
DEST_DIR=${DOM_DIR}/${dom%.*} # destination dir = removed .disabled
[ ! -e ${DEST_DIR} ] && ln -s suspend ${DEST_DIR}
fi
done

###################################################################

for mov in $MOVED
# if dommain has been enabled
do
DOMAIN=${mov%.*} # remove .dsiabled string from it
[ -e ${DOM_DIR}/${DOMAIN} ] && unlink ${DOM_DIR}/${DOMAIN} # unlink domain if exists
mv ${DOM_DIR}/suspend/${mov} ${DOM_DIR}/${DOMAIN} # move folder *.disabled to its original position
done

change script to meet your needs, save it, name it whatever you like and after
place it in your cronjob (crontab -e then type five asterisks followed by the path of this script)
Here is the good link for crontab howto:
http://blog.fekw.de/2008/04/05/cronjob-crontab-howto/
Happy new year all... Big Grin
(This post was last modified: 01-01-2009 12:19 AM by xokaido.)
12-31-2008 11:54 AM
Find all posts by this user Quote this message in a reply
Blondak Offline
Junior Member
*****
Dev Team

Posts: 84
Joined: May 2008
Reputation: 5
Post: #3
RE: Domain Disabled message howto?
Hi,
I'm writing patch that allows set redirect page, but I am not sure where setup target URL, somewhere in reseller properties? Or hidden (for customers) part of Hosting plan , which is transferred to domain properties (editable per user)?

What do you think?

EDIT:
OK, i have complete this patch Ticket 266. Reseller can set (under "Edit Domain") "Redirect disabled domain" and enter URL to which is disabled domain redirected.
Patch is made against current trunk.
(This post was last modified: 09-05-2009 12:14 AM by Blondak.)
09-04-2009 09:29 PM
Visit this user's website Find all posts by this user Quote this message in a reply
lambwell Offline


Posts: 2
Joined: Jan 2010
Reputation: 0
Post: #4
RE: Domain Disabled message howto?
Hi,
It means you cannot link directly to files on their server.
for instance they might have an image on a page and you want it to appear on your page so you use the full url in your image tag to link to the file. some servers don't allow this.
download the file to your hard drive then upload it to your own homepage directory
or upload it below and get the html source code on the next page to paste on your page
01-11-2010 04:22 PM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)