mediatemple

Deploying site with Git: post-update hook works first time, then never again

前提是你 提交于 2019-12-31 06:55:06
问题 Having a strange issue with a git post-update hook. I created repository on my server ( /var/www/vhosts/git/master.git ) and in this repository added a post-update hook with the following code: #!/bin/sh echo $1 echo "*UPDATE*" case " $1 " in *'refs/heads/master'*) GIT_WORK_TREE=/var/www/vhosts/website.com/sandbox.website.com git checkout -f echo echo "Master was updated!" echo ;; esac case " $1 " in *'refs/heads/sandbox'*) GIT_WORK_TREE=/var/www/vhosts/website.com/sandbox.website.com git

Not being prompted to download CSV file

青春壹個敷衍的年華 提交于 2019-12-24 05:44:05
问题 I've created a custom solution in WordPress that will generate a CSV file to be downloaded by clicking a simple hyperlink, linked directly to this file. Instead of being prompted to download the file to the computer; the CSV opens in the the browser window instead. FWIW I'm on Media Temple using a vanilla install of WordPress. 回答1: Send the proper mime type header('Content-type: text/csv'); And use the Content-Disposition header to tell it to download: http://www.jtricks.com/bits/content

How do I enable XSLT functions in PHP 5?

自作多情 提交于 2019-12-12 08:34:07
问题 I'm wanting to print an xml file out as an HTML nested list using xslt, and as far as I know the code is correct, however I'm getting this error Fatal error: Call to undefined function xslt_create() Which I presume means the xslt functions havn't been enabled. How do I enable these functions within PHP? Is there a php file I need to include (like the way Javascript libraries work) or is it something more complicated? I'm hosted with MediaTemple. Here's the php code I'm using: <?php //

How can I check if I have mysqli in my web server using cPanel?

我的梦境 提交于 2019-12-11 13:40:19
问题 I'm using... PHP version 5.4.28 Filezilla Wordpress cPanel MediaTemple hosting I get this error Fatal error: Call to undefined function mysqli_connect() , after trying to connect to my database with mysqli functions. I've read online that either mysqli isn't enabled, it may not be installed. I know I have to check my php.ini file located in /usr/local/lib/, but I don't how know look for that. I'm using cPanel's WHM and it looks like this... cpanel WHM Any suggestions? 回答1: If you have WHM you

“Invalid ns” when connecting to mongodb server

梦想的初衷 提交于 2019-12-11 08:21:28
问题 Im trying to connect to a MongoLabs mongodb server I setup for a small project Im working on. I can connect fine when connecting from my local machine, but when I try to make a connection from my Mediatemple server I get a 'Invalid ns' error: Unable to connect to MongoDB: Failed to connect to: dsXXXXXX.mongolab.com:27769: send_package: the query returned a failure: Invalid ns [XXXXXX_dev/XXXXXX_dev.$cmd] (code: 16256) Any suggestions on how to fix this would be a major help. 回答1: Perhaps your

How do I enable XSLT functions in PHP 5?

主宰稳场 提交于 2019-12-04 04:28:49
I'm wanting to print an xml file out as an HTML nested list using xslt, and as far as I know the code is correct, however I'm getting this error Fatal error: Call to undefined function xslt_create() Which I presume means the xslt functions havn't been enabled. How do I enable these functions within PHP? Is there a php file I need to include (like the way Javascript libraries work) or is it something more complicated? I'm hosted with MediaTemple. Here's the php code I'm using: <?php // Allocate a new XSLT processor $xh = xslt_create(); // Process the document, returning the result into the

Need advice on deploying my first rails app to a mediatemple (dv)

懵懂的女人 提交于 2019-12-03 10:17:34
问题 I'm trying to deploy my first rails app on a mediatemple (dv) and i'm not having any luck. I'm trying to use phusion passenger so i went over to http://www.modrails.com/videos/passenger.mov and watched the tutorial on installing this. I did everything with no issues and I'm when i point to my ip, i see an apache page and not my rails app. I noticed that on mediatemple, I had to create a vhosts.conf file and run a command to reconfigure my project to look at this vhosts.conf file. Reference -

php Contact Form on website and reply-to email

旧时模样 提交于 2019-11-28 11:36:14
I have a PHP Contact form on a site I am hosing on our mediatemple grid server that was made with Rapidweaver. It works well except that the email it generates to our info@ourdomain.com is sent as serveradmin@ourdomain.com. I think the server is just using the trash/blackhole address. Any way to adjust my php or better yet, the server settings, to send the mail as the reply-to address that the user fills out on the contact form itself? Why? Well Google hosts the email for this domain and I wanted to use their canned responses as an auto-responder. The problem of course, is that the auto

php Contact Form on website and reply-to email

我怕爱的太早我们不能终老 提交于 2019-11-27 06:22:09
问题 I have a PHP Contact form on a site I am hosing on our mediatemple grid server that was made with Rapidweaver. It works well except that the email it generates to our info@ourdomain.com is sent as serveradmin@ourdomain.com. I think the server is just using the trash/blackhole address. Any way to adjust my php or better yet, the server settings, to send the mail as the reply-to address that the user fills out on the contact form itself? Why? Well Google hosts the email for this domain and I

Gmail SMTP debug: error “please log in via your web browser” [closed]

懵懂的女人 提交于 2019-11-26 06:05:55
I'm having problems with gmail smtp server. I already read many posts here in StackOverflow about that subject. The best post I found about test the connection is this one . Although it is very well explained the error I'm getting I couldn't find a answer: Google SMTP just says "Please log in via your web browser and then try again". I'm completely sure that the password and the email (both in base64) are well encoded. As you can see here, in this image: , there is just one difference I can notice: the user@gmail.com and password is sent in two steps. In the link above the guy sends both at