Får följande fel "No input file specified." när jag skall öppna en sida med formulär hos B-one, men lokalt så funkar det, där har jag senaste PHP5 och hos B-one så har jag valt PHP5.
I en annan tråd hittade jag lite om detta och man hänvisade till php.ini men den kommer ju inte jag åt på hotellet.
(Tilläggas kan att jaginte valt B-one utan kunden!)
Vad göra???
<?php session_start(); // Alltid överst på sidan ?>
<?php require_once('../Connections/connections.php');
// Kolla om inloggad = sessionen satt
if (!isset($_SESSION['sess_user'])){
header("Location: login/index.php");
exit;
}
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $theValue;
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
$editFormAction = $HTTP_SERVER_VARS['PHP_SELF'];
if (isset($HTTP_SERVER_VARS['QUERY_STRING'])) {
$editFormAction .= "?" . $HTTP_SERVER_VARS['QUERY_STRING'];
}
if ((isset($HTTP_POST_VARS["MM_insert"])) && ($HTTP_POST_VARS["MM_insert"] == "Add_form")) {
$insertSQL = sprintf("INSERT INTO sidor (idnr, header, brodtext, link, bild) VALUES (%s, %s, %s, %s, %s)",
GetSQLValueString($HTTP_POST_VARS['idnr'], "int"),
GetSQLValueString($HTTP_POST_VARS['header'], "text"),
GetSQLValueString($HTTP_POST_VARS['brodtext'], "text"),
GetSQLValueString($HTTP_POST_VARS['link'], "text"),
GetSQLValueString($HTTP_POST_VARS['select'], "text"));
mysql_select_db($database_connections, $connections);
$Result1 = mysql_query($insertSQL, $connections) or die(mysql_error());
$insertGoTo = "index.php";
if (isset($HTTP_SERVER_VARS['QUERY_STRING'])) {
$insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
$insertGoTo .= $HTTP_SERVER_VARS['QUERY_STRING'];
}
header(sprintf("Location: %s", $insertGoTo));
}
mysql_select_db($database_connections, $connections);
$query_Rc_Bild = "SELECT B_name FROM upload ORDER BY id ASC";
$Rc_Bild = mysql_query($query_Rc_Bild, $connections) or die(mysql_error());
$row_Rc_Bild = mysql_fetch_assoc($Rc_Bild);
$totalRows_Rc_Bild = mysql_num_rows($Rc_Bild);
?>
<?php echo "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?".">"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Add sida</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="../stylesheets/mossedal_1.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form action="<?php echo $editFormAction; ?>" method="POST" name="Add_form">
<table align="center">
<tr valign="baseline">
<td nowrap align="right"> </td>
<td><h3>Lägg till sida</h3></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap class="orangeTable">Överskrift:</td>
<td><input type="text" name="header" value="" size="32">
Max 32 tecken
<input name="idnr" type="hidden" id="idnr" /></td>
</tr>
<tr valign="baseline">
<td align="right" valign="top" nowrap class="orangeTable">Brödtext:</td>
<td><textarea name="brodtext" cols="150" rows="20"></textarea></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap class="orangeTable">Länktext:</td>
<td><input name="link" type="text" value="" size="32" maxlength="15">
Max 15 tecken</td>
</tr>
<tr valign="baseline">
<td align="right" nowrap class="orangeTable">Bildfil:</td>
<td>
<select name="select">
<option value="value"></option>
<?php
do {
?>
<option value="<?php echo $row_Rc_Bild['B_name']?>"><?php echo $row_Rc_Bild['B_name']?></option>
<?php
} while ($row_Rc_Bild = mysql_fetch_assoc($Rc_Bild));
$rows = mysql_num_rows($Rc_Bild);
if($rows > 0) {
mysql_data_seek($Rc_Bild, 0);
$row_Rc_Bild = mysql_fetch_assoc($Rc_Bild);
}
?>
</select>
Bildnamn.</td>
</tr>
<tr valign="baseline">
<td align="right" nowrap class="orangeTable"> </td>
<td><input type="submit" value="Infoga post"></td>
</tr>
</table>
<input type="hidden" name="MM_insert" value="form1">
<input type="hidden" name="MM_insert" value="Add_form">
</form>
<p><a href="index.php" target="_self">Admin startsida</a></p>
</body>
</html>
<?php
mysql_free_result($Rc_Bild);
?>