can i configure .htaccess to direct browsers to a different css file based upon their browser type?
That's the short question. The longer question is: how do I set up my .htaccess file to call a different css file based on mobile browsers?
All I want to do create a 2nd version of a css file so that my site's content, when viewed on a mobile browser, calls /mobi/style.css instead of /style.css.
I have the rewritecond statement for all the mobile browsers, and in fact I presently direct all mobile browser traffic to a designated static webpage, which you can see at tastyplacement . com which directs to tastyplacement . com/mobi.
But if I could simply call a different css file, I could have the pages load as they normally would but with a different css file and thus an entirely different look for the website (narrower columns, no header navigation, ie., a stripped down version of the site with the main text intact).
My question is, are the visitors a day accurate - which I take to be uniques. It seems these must be pretty far off.
Presently they show an extremely high multiple of that for pages/s (approx 30 -50 times the visitors). I've never heard of visitors clicking this many pages.
I've not come across these kind of number with other non-mobile sites and it makes wonder if its right.
A) is tracking handled in the same way on mobile devices as on desktops (cookies or sessions?) And is this reliable for mobile/handheld/cell-phone devices?
B) There really isn't much of a chance of these page views being a result of bookmarks - the page views don't seem to add up to this.
The 'Browser Top 10' hits coming from 'unknown' are > 50% of the total amount.
Are there any quirks with awstats or other tracking software when it comes to mobile devices, even though the activity is taking place on the server? I take it Urchin may be more accurate?
I received an error message "Error: Failed to remove mobile site: Can't delete a site that's not active " when try to remove a mobile website in Plesk control panel and if i try to edit site content i received another error message "Can't access a site that's not active" from [URL] ....
These notification messages are originating from UNITY Mobile platform. The reason is actually hinted in the messages themselves - both the site and the editor account have been already disabled and there are no handlers anymore to modify their status further, so the messages are correct from UNITY Mobile platform's standpoint.
It appears that Plesk control panel has somehow retained in its configuration information about the site availability and is giving the plesk control panel the option to configure the mobile site despite the fact that UNITY Mobile platform is returning "deleted" status back to Plesk. Plesk should be given an option to create a new site instead now.
I would like to know how to manage Plesk in this situation.
I'm trying to learn htaccess, but I'm having issues wrapping my head around this. I need to learn by example. Have several types of 301 permanent redirects that are needed.
Want to redirect a single page to a new page OLD - [url] NEW - [url]
Want to redirect a folder, AND any pages in it (preferably without naming EACH page), to a new folder's index OLD - [url] NEW - [url]
Want to redirect a subdomain to the primary domain OLD - [url] NEW - [url]
Want to redirect a folder, AND any pages in it, to a new subdomain OLD - [url] NEW - [url]
Using ISAPI_Rewrite 3 on 2003/IIS6, which uses htaccess commands.
Could anybody here show me what they would do in these scenarios?
I've read and read, and tried and tried, but it never seems to work out correctly. It either fails to redirect, or it redirects too much (some "open" type commands with a lot of variables will pick up the keyword -- for example, "students" -- so students.domain.com AND domain.com/students AND domain.com/program/students.html would all redirect, even though I only wanted the subdomain version, or the page version, to redirect, and not the others!).
I have what I think is kind of a unique situation with a site move and Google is not turning up an answer that seems to work.
My site is currently in this format:
www.mydomain.com/site/file.html
And I am "moving" it but also switching from html to php, so the same file would be found at:
site.mydomain.com/file.php
I want to redirect users going to the old pages to their equivalent on the new site, however this is a little bit of a problem because this is a normal subdomain - it is the same directory as before but now there are php versions of the html files.
Right now I have all of the http files redirecting to their php equivilents, but I don't believe this is a desirable solution. Also it creates a problem when people go to www.mydomain.com/site (not indicating a specific file; just the subdir root) because I have www.mydomain.com/site/index.html redirecting to www.mydomain.com/site/index.php.
Quite a mess.
My first option is to put the redirects in the htaccess file on the "old" site. But is this a problem because there are over 500 pages on the site? Does it create a heavy server load because any requests force the server to serve a huge htaccess file?
The next alternative seems the most preferable although I'm not sure how to do it. It seems it could use wildcards so that anyone going to *.html gets directed to *.php or something like that. The only problem is that there are a small number of files that were removed completely and do not have php equivilants (about 5 or 6) and would need to redirect to the index.php in the root
I have the following RewriteRule directive in my htaccess file on my localhost:-
Code: RewriteRule ^([a-z-]+)/?$ test.aspx/app.nav/params.class.com${meta:$1}/whatever${meta:$1} The rewrite rule works perfectly, since the revised URL is still preserved when after it is executed; I presume this is since my old URL is relative, and it's performing an internal rewrite.
However, when I make my old URL absolute (adding an external address to it), whenever I execute my new URL, I'm redirected to the external sites URL (which includes the same URL parameters as my internal 'test.aspx' page), like below:-
Code: RewriteRule ^([a-z-]+)/?$ http://www.example.com/test.aspx/app.nav/params.class.com${meta:$1}/whatever${meta:$1} Purely for demo purposes, upon execution, I'd like my new URL to be preserved in the address bar whilst, I'm redirected to the external site.
Is this possible to do - something like forcing the behaviour of an internal rewrite?
EDIT: I've done some investigating and people with similar problems have suggested using the Passthrough handler - although I'm slightly unclear as to what this does exactly, I gave it a go (adding '[PT]') at the end of RewriteRule, but unfortunately this didn't make any difference.
I have SSL enabled site on IIS.I want to access it from my PocketPC(Win mobile).But when I try access it, I have been prompted to install a certificate.
Unlike when I try to any HTTPS site (Banking sites) I have never been prompted to install any certificate.
Why am I being prompted with security message with "Yes,No,View certificate" options on it every time I try to access my own server(desktop) via my WIN mobile using active sync. Unlike When I try to access banking site(https) I was never ever prompted a mesage like above.
How to have same functionality for my application also?
to launch a web/mobile app that requires the users to choose a hosting plan with their account. I was hoping to allow them to choose from 1GB / 5GB and 10GB plans.
I'm curious to know the best place to host such a service, and how it's possible to sell the space so cheap. For example [url]- They seem quite inexpensive for the storage you get.
Would[url]pricing be the best option or is there anywhere better?
i have read somewhere you can logon to your server via ssh on your mobile phone. Anyone know what software is needed and how to do this? I'm off on holiday at some point and i could do with an emergency backup plan! I use a Sony ericcson p900 (oldschool i know!)
My 2nd question is:
What enables/disdabled php to access files outside of root? On my current vps, i can't include files like using ../ or full paths to files/folders outside of the public web folder.
I am interested if anybody knows who provides mobile satellite internet access?I would like to access the internet from anywhere in the world?. What are the costs? Do they have different speed plans?
We have a customer requirement to enable Direct Push email on our Outlook Web Access servers to a number of mobile devices the customer will be supplied from Vodafone - running Windows Mobile 5
Therefore we need to create a public HTTPS address to allow access to the OWA/OMA part.
We do NOT (at this stage) want to allow general access to OWA over HTTPS (we have an eGap solution with RSA for this) so we need to be able to lock down access to the OWA server only to specific devices. One way would be to use Firewall Rules at the Outer DMZ and lock down by the IP ranges of the phone but thats prohibitive to other devices and will fail when the phones change IP (i.e. international roaming)
Therefore Im wondering if we can use self signed SSL certs where there is no trusted CA provider (if there was all browsers would simply be prompted to trust the source and then get access). If we use our own self signed certs and have them installed on the client devices would this work? What would be the downsides (i.e. less cryptogrpahy without the CA part?)
As we are planning to implement Mobile for our platform, we want to distinguish between request coming from Mobile and Web in Apache. We will be using Apache for Reverse Proxy and we want it to differentiate the request source and forward it to required destination.Is this possible ?
I have recently upgraded mysql server from 5.0.75 to 5.1.31 on my Ubuntu server 9.04 32 bit. After that when I am running phpmyadmin it is printing a warning :
Your PHP MySQL library version 5.0.75 differs from your MySQL server version 5.1.31.
We have an established site for which we want to add a 'mobile-appropriate' subdomain geared to phone surfers.
Our host (1and1) confirms their servers detect mobile visitors but they couldn't help me with how to read the server flag(?) or whatever and then redirect the server to our mobile subdomain when appropriate.
Can anyone point to an appropriate how2? (Note I don't need "mobile code" help help - just help with how to redirect mobile visitors transparently off our main site and into its mobile subdomain).
I have a Windows Mobile 6 (Blackjack II) phone that I am connecting to my cpanel VPS via Pop3.
I have a number of pop3 accounts setup to check for email every 30 minutes. However, every couple days the phone stops downloading mail and if I do a manual send and receive I get a "The Server Certificate is not valid. Continue Anyway?" with a yes/no. If I click yes, the email downloads and then the automated emails will work for several days and then the process is repeated.
Does anyone know how to either disable this check on the phone (no luck finding that yet), or to install the certificate from the cpanel mail server to the phone?
I have experimented with the Startcom free SSL certificates but would now like to install a low cost certificate on an Outlook Web Access server that Windows Mobile 5 devices will trust without having to load stuff onto each device.
Has anyone tried any online backup services which gives mobile access also. I have been thinking about trying one. But I'm not sure if any are better than others. My main concern is security.
Can anybody recommend a free or paid webmail application which can be used on a mobile (specifically a blackberry 8100). I need a way to access my emails via a webpage... I can't have all emails forwarded to my phone, as there are way to many. As there are a fair few emails in my inbox the application would need to be able to handle a large number of emails.
loading a phpinfo() shows that the mysql variable "Client API version" on my server doesn't match the version of mysql installed ( 4.0.20 when mysql version is 4.1.21).
Can this cause trouble and php or mysql errors on scripts i'm running?
Attached is a (badly) drawn diagram of two sites, connected by a vpn.
The site to the left, is network 10.0.0.0/24 which runs a linux server as the router for the network.
The site to the right, is network 10.1.0.0/24 which runs a windows 2003 server as the router for the network.
Now, my problem is, the clients behind the windows 2003 server can ping any machine on the first network because i setup a static route to route all traffic to 10.0.0.0/24 over the vpn interface.
now, my problem is, only the linux server can ping any machine on the windows 2003 network, any client behind the linux server cant seem to route over the interface.
I have the following route on the linux server: .....
Starting point: a working site using a shared IPv4, dedicated IPv6, and SSL. HTTP and HTTPS work, the latter only using SNI of course.
The good news: If I simply allocate an IP resource of 1 to a subscription it is pulled from the pool, assigned to the service node, assigned to the web site, DNS is updated, and the site is automatically changed to using a Dedicated IPv4 and Dedicated IPv6.
The bad news: visitors land on the default web site of the service node, with the default SSL certificate.
Other info: I can't ping the new IP, even though it shows in "ip a l" and /etc/sysconfig/network-scripts/ifcfg-eth0:0. [edited]
After the IP assignment, it is still installed, and /etc/httpd/conf/plesk.conf.d/ip_default/domainname.conf shows the new certificate is being used.
However, a second set of VirtualHost entries is created in server.conf for this IP for ports 80 and 443, with NameVirtualHost enabled on the new IP. The port 443 entry uses the default certificate. Apache's setup this default VirtualHost entry will override the web site configuration because Apache is listening on port 443 with the wrong cert.
If I go to "Change webspace settings" and toggle to Shared IPv4, Dedicated IPv6 the site works again via HTTPS, and Dedicated IPv4 and Dedicated IPv6 breaks it again. Setting the SSL cert to None and back again does not work.
Setting the SSL cert to None, changing to a dedicated IP, and enabling SSL results in the server being inexplicably inaccessible...browsers no longer connect to either the default site or the correct site, and I don't see any entries in the vhosts's logs.
I noticed when installing latest version of APF 0.9.6.3 over the previous version 0.9.6.2 it will import all the variable and ports settings from conf.apf and allow_hosts.rules files of the previous version. so there will be no need to edit or configure any thing any more when upgrading APF exept setting DEVEL_MODE to 0 and restart APF.