implode

    -3熱度

    1回答

    我不知道PHP,但我必須在其中工作。我需要添加到$attr['ids']數組與$gallery_setting。 function the_featured_image_gallery($atts = array()) { $gallery_setting = get_theme_mod('featured_image_gallery'); if (is_array($ga

    0熱度

    2回答

    我有這樣的代碼: HTML複選框名稱: name="selection[]" 代碼: $selections = $_POST['selection']; $selectionsview = implode("<br>", $selections); echo $selectionsview; 這僅僅是預覽輸出,然後: $selectionsfull = implode(PHP_EO

    0熱度

    3回答

    我已經將複選框數據轉換爲一個字符串存儲在我的數據庫中。 但是,當我嘗試使用爆炸函數將字符串轉換回數組時,我無法在in_array中搜索除第一項外的任何內容。爲什麼? $rolepref = explode(',', $roles); print_r($rolepref) = [0] Strategy [1] Operations if (in_array("Strategy", $rolepr

    -1熱度

    2回答

    確定我有這個 $eng[] = "All"; $eng[] = "engine_Sigma"; $eng[] = "engine_K-Series"; $eng[] = "engine_Duratec"; $eng[] = "engine_Suzuki"; $eng[] = "engine_Vauxhall"; $eng[] = "engine_Crossflow"; do {

    0熱度

    1回答

    $allProfiles = ''; foreach(array_merge($profile, $otherProfiles) as $all): $allProfiles .= $all; endforeach; echo "Player all profiles: $allProfiles"; 這爲我打印Player all profiles: NameNameName

    1熱度

    3回答

    每當我嘗試將某些內容更新到我的數據中時,我總是收到此錯誤。它最後一次沒有發生很多事情,但在放入新的更新函數後,錯誤不斷出現,出於某種原因,它指向我已經輸入的新函數,即使我正在更新舊函數。 控制器: //update for user public function edit($id){ $object = user::find($id); return view

    -1熱度

    2回答

    我想Impload在我的陣列中的所有本地字符,但是當我impload輸出僅 0K11LS19T20B2C32M13NU21V1 我需要創建另一個陣列爲其他字符或有一些錯誤的,我的代碼? <?php $alphNm = array ( array("tag" => "A1B2C","tag" => "3D4E5","tag" => "F6G7H","tag" => "8I9J1

    1熱度

    2回答

    HII我有2級foreach循環這樣的,我想從每個環路刪除最後一個逗號, /* Here is the mysql query */ foreach($loop1 as $val1){ $showvalone = $val1['data1']; echo "[".$showvalone; /* Here is the second MySQL query conne

    1熱度

    4回答

    我有以下陣列,其包括ID: [Key1] => 1 [Key2] => 2, 3 我想通過它們各自的名稱從該第二陣列來取代這些ID: [0] => Array ( [ID] => 1 [Name] => Name1 ) [1] => Array ( [ID] => 2 [Name] => Name2 )

    1熱度

    1回答

    我想轉換以下數組: array (size=6) 0 => array (size=1) 1 => string '611' (length=3) 1 => array (size=1) 1 => string '610' (length=3) 2 => array (size=1) 1 => stri