[Solved] input data codeigniter always 0 on database

You don’t have a valid submit button in your html code. Remove your link and use an input type “submit” or a button Replace : <div class=”form-group”> <a href=”https://stackoverflow.com/questions/29392261/<?= base_url() ?>ipmpab/addIpMpabDb/” class=”btn btn-success”> <span class=”glyphicon glyphicon-plus”></span> add </a> </div> With : <div class=”form-group”> <button type=”submit” class=”btn btn-success”> <span class=”glyphicon glyphicon-plus”></span>add </button> </div> … For exemple … Read more

[Solved] how to make thread in c++

_beginthread is a Visual C++ CRT function. I don’t recommend using it or process.h for this purpose. Please use std::thread (or if your compiler is older, boost::thread). If you were using _beginthread, you’d give it tdrow, not tdrow(). 1 solved how to make thread in c++

[Solved] What does below pointer syntax mean [duplicate]

The three are same. The only differences are, The position of the asterisk and the whitespace around them(which is done according to one’s preference) The string literals “blah” could be stored in the same memory location or different locations. From the C11 standard, 6.4.5 String literals […] It is unspecified whether these arrays are distinct … Read more

[Solved] extracting power from polynomials

Problems: If the user enters something that doesn’t contain a ‘^’, then your code exhibits Undefined Behavior as num is not initialized here if(isdigit(num)) If the input does contain a ‘^’, then the if will be true. Here: strcat(power,parts[k]); strcat finds the NUL-terminator in its first argument and overwrites its second argument from that position. … Read more

[Solved] I need to get the corresponding number after * in the string

Hi is the number still part of the string ? if does, maybe you can use explode. <?php $num = “* 2 * 3 * 5”; print_r (explode(“*”,$str)); ?> I hope it helped you. 🙂 ——-UPDATED—————– $str=”first string * 2 + second string * 4 + third string * 9″; preg_match_all(‘!\d+!’, $str, $matches); print_r($matches); 5 … Read more

[Solved] How do I fix Rails RuntimeError Current ExectJ doesn’t support ES5?

The main problem was in your Gemfile here gem ‘therubyracer’, platforms: :ruby gem ‘mini_racer’, platforms: :ruby You had two racer type gems, you only need one. You should just use gem ‘mini_racer’ and get rid of therubyracer. Do that and run bundle install. You will also need to clean up merge conflict stuff left in … Read more

[Solved] I want to plot the count of over a specific number e,g 2000 [closed]

You can assign the result of the value_counts() to a Series and filter it as below: count = df_1[‘neighbourhood’].value_counts() ax = count[count > 2000].plot(kind=’bar’, figsize=(14,8), title=”Neighbourhood that showed”) ax.set_xlabel(“neighboorhood”) ax.set_ylabel(“Frequency”) solved I want to plot the count of over a specific number e,g 2000 [closed]

[Solved] Getting this format in output [[20, 33], [20, 33], [20, 33], [10, 22], [10, 22], [10, 22]], but i want my output such as [20, 10] [33, 22] [closed]

Getting this format in output [[20, 33], [20, 33], [20, 33], [10, 22], [10, 22], [10, 22]], but i want my output such as [20, 10] [33, 22] [closed] solved Getting this format in output [[20, 33], [20, 33], [20, 33], [10, 22], [10, 22], [10, 22]], but i want my output such as [20, … Read more

[Solved] Why does the array keep reverting to 0

You declare unsigned short hex_v_info (2 bytes on my system), then read data from with fscanf(fp ,”%x”, &hex_v_info) where the format string %x expect the address of an int (4 bytes on my system). This will certainly overwrite data unexpectedly. unsigned short **v_info but you store an array of int [s_votes]. If your pointers are … Read more

[Solved] Printing key value pair in Laravel blade using for each loop [closed]

Your code is a mess. here is a cleaner version without using the models (since you did not say if they are in place) Controller Code public function show_friend_request() { $user_id = auth()->user()->id; $senderIds = DB::table(‘friendships’)->where(‘recipient_id’, $user_id)->where(‘status’, ‘pending’)->pluck(‘sender_id’)->toArray(); $activeRequests = DB::table(‘users’) ->whereIn(‘id’, $senderIds) ->get([‘first_name’,’last_name’]); return view(‘pages.friend_request’)->with(‘activeRequest’, $activeRequests); } Blade Code @foreach($activeRequest as $key => $friend) … Read more

[Solved] Get specific data from a string? C#

I solved it!! Thank your comments and suggestions..I’ll improve the way I question.. HAHAH I hope you guys and gals get the logic. Quite simple 🙂 string group = “|17|11|05|”; string[] words = group.Split(‘|’); foreach (string word in words) { if (word.ToString() != “”) { string cg = word; } } 1 solved Get specific … Read more

[Solved] how to upload images in a table field in my [closed]

Don’t store images in your database, just store the references to them (file names or paths). If there will be more than one image per movie, then you will have a table representing this one-to-many relation: CREATE TABLE movie_images (movie_id int, image varchar(255)); For each image, insert a row: INSERT INTO movie_images (movie_id, image) VALUES … Read more