如何使用gsutil命令在Google云存储中的存储桶中创建新文件夹?
我尝试在创建存储桶时使用相同的命令但仍然出错
gsutil mb -l us-east1 gs://my-awesome-bucket/new_folder/
Run Code Online (Sandbox Code Playgroud)
谢谢!
在我的$result变量里面我有一个5行字符串:
0100014746510106200140001020061780000000041666670072860103508101 0100008030950106200270002020139450000000020000006663540105338500 0100004586400106200270002020206660000000003700000511890102603900 0100008204530106200270002020218320000000011666670014450101008906 0100015309660106200270002021023010000000019400001666460105319807
我怎么能substr()每一行......为了得到这个结果:
010001
010000
010000
010000
010001
只需要获得每行的前6列...请帮助...
PHP代码:
$file = 'upload/filter.txt';
$searchfor = $_POST['search'];
$filename = $_POST['filename'];
$btn = $_POST['button'];
if($btn == 'GENERATE' ) {
//prevents the browser from parsing this as HTML.
//header('Content-Type: text/plain');
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-Type: application/force-download");
header("Content-Type: application/octet-stream");
header("Content-Type: application/download");;
header("Content-Disposition: attachment;filename=".$filename.".txt ");
header("Content-Transfer-Encoding: binary ");
// get the file contents, assuming the file to be readable (and exist)
$contents = …Run Code Online (Sandbox Code Playgroud) 我有一个评论框,用户可以发表评论.这些注释将在while循环中显示.
<?php
while ($rowsx=mysql_fetch_array($resultss1)){
echo "<div id='comments'>";
echo "<table class='table11'>";
echo "<tr>";
echo "<td class='sss'><img src='img/user.jpg'>";
echo "<p class='p999'>" .$rowsx['username'];
echo "</p> </br>";
echo "<p class='p9date'>" .$rowsx['date_posted']. "</p> ";
echo "</td>";
echo "<td>";
echo "<p class='p9'>" .$rowsx['comment']. "</p> </br></br></br>";
echo "</td>";
echo "</tr>";
echo "</table>";
echo "<a href='reply1.php?r_comment=".$rowsx['comment']."&prod_id=".$row['prod_id']."' class='reply_button'> REPLY </a> ";
echo "</div>";
}
?>
Run Code Online (Sandbox Code Playgroud)
现在其他用户也可以回复用户的评论.我想在其他用户的每个评论下面显示他们的回复,但我似乎无法弄清楚如何做到这一点.
我应该在第一个while循环中使用另一个while循环吗?
对不起,如果我使用mysql函数,我知道它已经折旧,但它只是一个学校项目.
这是我显示评论的查询:
$display_comments1="Select username,prod_id,comment,DATE_FORMAT(date_posted, '%m/%d/%Y %H:%i:%s' ) AS date_posted from comment where prod_id='$prod_id' order by date_posted DESC";
$resultss1=mysql_query($display_comments1);
if($resultss1 === FALSE) { …Run Code Online (Sandbox Code Playgroud) 我想替换2013-2-2为2013,2,2
我试过了
var forrep = '2013-2-2';
var text = forrep.replace('-', ',');
Run Code Online (Sandbox Code Playgroud)
但它只替换了第-一个输出看起来像这样2013,2-2
我希望所有的东西-都被,commna 取代
请帮忙谢谢