remote-server

Php upload image to remote server with cURL

喜欢而已 提交于 2019-11-27 07:04:43
问题 I would like to use cURL in php to upload an image to a remote image server. I have this piece of code, it's on the webserver: <form enctype="multipart/form-data" encoding="multipart/form-data" method="post" action="webform.php"> <input name="somevar" type=hidden value='.$somevar.'> <input name="uploadfile" type="file" value="choose"> <input type="submit" value="Upload"> </form> and: if (isset($_FILES['uploadfile']) ) { $filename = $_FILES['uploadfile']['tmp_name']; $handle = fopen($filename,

Recieving a 403 forbidden error when using latitude and longitude: geocoding

寵の児 提交于 2019-11-27 05:30:14
Our site has the option to insert your postcode in, which in turn works with geocoding to work out the latitude and longitude. This code has not been changed for years but today if the user trys to insert a postcode or update it from yesterday or before the error 'The remote server returned an error: (403) Forbidden.' pops up. The requests have not shot past 2,500 so I cant see Google blocking us because of that.. Any ideas?? The version 2 Geocoding API was turned off September 9th as announced... From Upgrading Your Geocoding API Application To v3 Version 2 ("v2") of the Geocoding API was

How to send data to remote server using Javascript

折月煮酒 提交于 2019-11-27 04:39:48
I need to send data to a remote server using javascript. How do I do this? Background info: There's a webpage from which I extract some information using JS, and I need to send it back to another server for processing. Response is not neccesary. The data is XML, Which I've URLencode'd. How would one do this? EDIT The server I'm requesting the data from is not the same that receives the data. Just to clarify. One of the most common ways to do this is AJAX. Here's how you perform an AJAX post request using jQuery: <script type="text/javascript"> $.post('/remote-url', {xml: yourXMLString }); <

How to connect to a remote Windows machine to execute commands using python?

百般思念 提交于 2019-11-27 03:58:48
问题 I am new to Python and I am trying to make a script that connects to a remote windows machine and execute commands there and test ports connectivity. Here is the code that I am writing but it is not working. Basically, I want to and it returns with the local machine data, not the remote one. import wmi import os import subprocess import re import socket, sys def main(): host="remotemachine" username="adminaam" password="passpass!" server =connects(host, username, password) s = socket.socket()

Connect to external server by using phpMyAdmin

落花浮王杯 提交于 2019-11-27 01:37:58
问题 I have phpMyAdmin installed on my local machine. How can I make it connect to an external server? 回答1: In the config file, change the "host" variable to point to the external server. The config file is called config.inc.php and it will be in the main phpMyAdmin folder. There should be a line like this: $cfg['Servers'][$i]['host'] = 'localhost'; Just change localhost to your server's IP address. Note: you may have to configure the external server to allow remote connections, but I've done this

How can I get MIBs list from a remote server by using PHP?

让人想犯罪 __ 提交于 2019-11-26 23:41:22
问题 I am working on a project that involves SNMP. Basically I need to construct MIB and OID tree in PHP. I know that there are programs that do this already, but I am trying to implement my own version to incorporate with my webapp. What I know : I am familiar with php SNMP function. I can do SNMPWALk to get OIDs and such. Unfortunately there is no function that I know of that finds all MIBs and parses them. What I need : Get all MIB docs first from remote server, then based on each docs get

Execute exe on remote machine

本秂侑毒 提交于 2019-11-26 23:38:53
问题 I'm trying to execute notepad.exe on a remote machine, but it's not working now. What am I missing? var ui = new ImpersonateUser(); //the process to restart const string processName = "notepad.exe"; var serverName = "serverName"; try { //Use adbadmin for access ui.Impersonate(_domain, _userName, _pass); //Start the process ProcessStartInfo info = new ProcessStartInfo("C:\\PsTools"); info.FileName = @"C:\PsTools\psexec.exe"; info.Arguments = @"""\\" + serverName + @"C:\WINDOWS\notepad.exe""";

Firebird: Unable to complete network request to host

别说谁变了你拦得住时间么 提交于 2019-11-26 22:03:25
问题 I'm trying to connect to a remote Firebird database "test" (alias already added). It is not an embedded server, and is installed on VM with IP 192.168.1.147. Here is my connection string: User=sysdba;Password=masterkey;Database=test;DataSource=192.168.1.147 However I got an error: FirebirdSql.Data.FirebirdClient.FbException (0x80004005): Unable to complete network request to host "192.168.1.147". ---> Unable to complete network request to host "192.168.1.147". I've done some research on that

How do we set remote in Typeahead.js?

痴心易碎 提交于 2019-11-26 14:25:22
In previous versions I could do: $('#search').typeahead({ name: 'Search', remote: '/search?query=%QUERY' }); But since the 0.10 update, typeahead.js is asking us to define source which I cannot make to work. How do I define remote without having to define a dataset function? Typeahead.js version 0.10.0 now uses a separate component called a suggestion engine for providing the suggestion data. The suggestion engine which ships with Typeahead.js is called Bloodhound . Hence you cannot "define remote without having to define a dataset function". An example of this working with a remote data

Recieving a 403 forbidden error when using latitude and longitude: geocoding

自古美人都是妖i 提交于 2019-11-26 11:36:26
问题 Our site has the option to insert your postcode in, which in turn works with geocoding to work out the latitude and longitude. This code has not been changed for years but today if the user trys to insert a postcode or update it from yesterday or before the error \'The remote server returned an error: (403) Forbidden.\' pops up. The requests have not shot past 2,500 so I cant see Google blocking us because of that.. Any ideas?? 回答1: The version 2 Geocoding API was turned off September 9th as