[Solved] How do I use PHP to apply css properties? [closed]

This is what you’re asking for, but it isn’t best practice and I wouldn’t recommend it. I would refer you to @nietonfir’s suggestion (despite being a little harsh, he/she is right). Doing mobile stuff in CSS as a part of a responsive design (media queries) is soooooo much better and easier. <?php if ($mobile == … Read more

[Solved] Compare 2 arrays of strings

Your code contains a lot of syntax errors. Please post actual code, I understand the issue you are talking about, that’s why I’m posting this answer. Please post questions with valid code, else you won’t get proper answer (Only get downvotes) Use the following code: NSArray *current = @[@”1″, @”6″, @”53″]; NSArray *newArr = @[@”1″, … Read more

[Solved] Error in android code [closed]

You can find the number of common characters by the following method. I have changed p to int bt1.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { ArrayList<Character> charArray1 = new ArrayList<Character>(); ArrayList<Character> charArray2 = new ArrayList<Character>(); for (char character : st1.toString().toCharArray()) { charArray1.add(character); } for (char character : st2.toString().toCharArray()) { charArray2.add(character); } for (Character … Read more

[Solved] Count down timer in php with database [closed]

You can store the target time in Mysql and you can fetch that target time in PHP and assign it to Javascript code, so the javascript will show the countdown timer. For countdown timer you can take any jquery script from here: http://www.tripwiremagazine.com/2012/11/jquery-countdown-scripts.html solved Count down timer in php with database [closed]

[Solved] how to set values in a 2d matrix [closed]

Here’s the Linq approach using Enumerable.GroupBy: List<string> strings = new List<string>() { “a”, “b”, “c”, “d”, “e”, “f”, “g”, “h” }; var trios = strings .Select((s, i) => new { Str = s, Index = i }) .GroupBy(x => x.Index / 3); foreach(var trio in trios){ var newRow = table.Rows.Add(); // your DataTable here newRow.ItemArray … Read more

[Solved] logic required in javascript

Your select tag should be <select name=”amt” id=”amt” onchange=”return totprice(this.value,2,110);” multiple> To make it multi select. Now when user will select multiple options (using Shift+click) then in your JavaScript function get these values and do the processing (provide discount/ any logic) Updated You wish to multiply the value the user has selected with the discount … Read more

[Solved] Condition inside table [closed]

Do you mean something like the following? echo ‘<td>’ . ($data[‘temperature’] < 5 ? ‘Cold’ : ‘Warm’) . ‘</td>’; The above uses the ternary operator as a contracted if/else within a table cell. 1 solved Condition inside table [closed]