Welcome Guest, Not a member yet? Register   Sign In
  flexigrid column width fit entire row
Posted by: El Forum - 10-23-2008, 05:07 AM - No Replies

[eluser]Unknown[/eluser]
Hello,

Is there a way to configure flexigrid, that the columns always use the entire row, regardless of their content? (like the behaviour of a classic html-table).

Unfortunately I wasn't successful with width='auto', but maybe this configuration isn't supposed to. (I tried some auto-width combinations with col-width & grid-width, too - no success)

Here is my example call (pretty basic)

Code:
\$("\#flex1").flexigrid
(
            {
            url\: '___DYNAMICURLPATH___',
            dataType\: 'json',
            colModel \: \[
                {display\: '', name \: 'act', width \: 'auto',  align\: 'left'},
                {display\: 'Name', name \: 'name', width \: 'auto',  align\: 'left'},
                
                \],
            buttons \: \[
                {name\: 'Question anlegen', bclass\: 'add', onpress \: addObject}
                            \],
                
#            searchitems \: \[
#                {display\: 'Name', name \: 'name', isdefault\: true},
#                {display\: 'Ort', name \: 'ort'}
#                \],
            sortname\: "name",
            sortorder\: "asc",
            usepager\: true,
            title\: 'Objekte',
            useRp\: true,
            rp\: 15,
            showTableToggleBtn\: true,
            width\: 'auto',
            onSubmit\: addFormData,
            onSuccess\: setAjaxForms,
            height\: 400
            }
            );

thanks for any advice!


  CI vs. Symphony
Posted by: El Forum - 10-23-2008, 04:07 AM - Replies (10)

[eluser]x386[/eluser]
What's the differences between CI and Symphony (php5 framework - http://www.symfony-project.org)? Which one is better?
Thank you!


  create our helper
Posted by: El Forum - 10-23-2008, 03:18 AM - Replies (2)

[eluser]alaminx[/eluser]
who can tell me how to create our helper and use it. Can u give me some code


  PHP stripping souble quotes on POST
Posted by: El Forum - 10-23-2008, 02:50 AM - Replies (4)

[eluser]Nathan Pitman (Nine Four)[/eluser]
Has anyone ever experienced a situation where PHP strips double quotes on a POST to a web service? We're running a web service on our server and after a PHP upgrade double quotes in serialized arrays that we are passing in the POST are being stripped... we're using NuSOAP.


  Search Engine Plugin
Posted by: El Forum - 10-23-2008, 02:25 AM - Replies (1)

[eluser]Amit Patel[/eluser]
Hello all,

I want to use third party search engine in my website with CI like phpdig ,isearch etc. So i want to ask is there any plugin available in CI for this type of search engine if no than how can i integrate it with CI any help will be appreciate.


Thank and regards,
----Amit Patel


  export to excel plugin
Posted by: El Forum - 10-23-2008, 01:11 AM - Replies (22)

[eluser]syntaxerror[/eluser]
hi,
where can i get the export to excel plugin?
cause my codeigniter doesnt have one.

thanks


  Memory utilization per page
Posted by: El Forum - 10-22-2008, 11:41 PM - Replies (1)

[eluser]Unknown[/eluser]
By enabling the profiling, it was found out that each page takes atleast 2MB when its loaded on browser

How can it be optimized? I am afraid that it would screw up if the site is visited by thousands of users at single time

How can I take care of it?


  Accessing a function directly
Posted by: El Forum - 10-22-2008, 10:55 PM - Replies (3)

[eluser]CodeIgniterNoob[/eluser]
I have a function that passes an id to a destination page that pulls data from a table based on that id. Everything works fine when the URL contains a number at the end like post/1, but when I hit the function directly like post/ it gives errors saying "Message: Missing argument 1 for welcome::post()" .

Is there a way to make that URL redirect to another page?


  Search Result and Pagination Error
Posted by: El Forum - 10-22-2008, 10:42 PM - No Replies

[eluser]Unknown[/eluser]
Hi everyone.
I'm quite new to programming and having a hard time doing this application. Ive been reading a lot of the topics here regarding searches and pagination, but i just cant seem to do it right. Can someone please help me? I would really appreciate it! :cheese:

Im doing a search engine displaying the program names. The search function is working but whenever the query reaches the page limit (example 10) and clicked the page 2 button of the pagination link, the items from my database are shown instead of the 2nd page from query result. Also, there's an error that says that theres an Undefined index, which is the $term (search keyword). BTW, Im using MS SQL.


Here's the controller:

Code:
<?php

class Pgmlist extends Controller {
    
    function __construct()
    {
        parent::Controller();
        $this->load->helper('url');     //creates a url link
        $this->load->helper('form');
        $this->load->database();
        $this->load->library('session');
      
    }
    
    function index()
    {
      
                $term = $_POST['term'];
            
                if(isset($_POST['term']))
                {
                 $this->session->set_userdata('term', $term);          
                }

                $this->session->userdata('term');
                $newdata = $this->session->userdata('term');
            
    
                 //load pagination class
                $this->load->library('pagination');
                $config['base_url'] = base_url().'index.php/pgmlist/index/'.$term;
                                            
                $config['total_rows'] = $this->db->count_all('saiyo');
                $config['per_page'] = '10';
                $config['full_tag_open'] = '<p>';
                $config['full_tag_close'] = '</p>';
          
                $this->pagination->initialize($config);
                        

  
                 //load model and get result
                 $this->load->model('search_model');
                 $data['result'] = $this->search_model->get_programs($term,  $config['per_page'], $this->uri->segment(3, 0));
                      
                //load the HTML table class
                 $this->load->library('table');
                 $this->table->set_heading('番組名');
                 $this->load->view('pgmlist_view', $data);  
}//end of controller

?&gt;



Here's the model:

Code:
&lt;?php

class Search_model extends Model{
    
    function search_model()
    {
        parent::Model();
    }//end of search_model function
    

    function get_programs($term, $num, $offset)
    {
    
       $sql = "Select TOP $num * from saiyo
        where programName not in
        (select top $offset programName from saiyo WHERE programName LIKE '%%$term%%' ) and programName
        like '%%$term%%' ";
        
       $Q = $this->db->query($sql);

        if ($Q->num_rows() > 0){
            foreach($Q->result_array() as $row)
            {
                $data[] = $row;            
            }
            $Q->free_result();
            return $data;              
              }

    }//end of search($term)function

    
}
?&gt;


The view:
(the following are only parts of the view)


Code:
&lt;?php
                echo form_open('pgmlist/index');
                
                $data1 = array(
                   'name' => 'term',
                   'id' => 'term',
                   'maxlength' => '50',
                   'size' => '50',
                   'style' => 'background-color:#f1f1f1'
                );
          
                echo form_input($data1);
                echo form_submit('submit', 'search');
                echo form_close();
       ?&gt;
      
    &lt;?php foreach($result as $row): ?&gt;
    <td>
    &lt;?php echo anchor('pgmlist/programs', $row['programName']); ?&gt;
    </td>
    </tr>
    &lt;?php endforeach; ?&gt;
        
    &lt;?php echo $this->pagination->create_links(); ?&gt;


  first segment in uri
Posted by: El Forum - 10-22-2008, 09:19 PM - Replies (1)

[eluser]dbashyal[/eluser]
is it possible to put dash in uri 1st segment

Quote:i.e. inplace of 'aboutus' can it be 'about-us' but load controller 'aboutus' no dash.

if yes, how can i do it?

Thank you.


Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Latest Threads
codeigniter4/queue Not lo...
by kenjis
2 minutes ago
Type error in SYSTEMPATH\...
by kenjis
1 hour ago
Depractaion request warni...
by kenjis
2 hours ago
Random 403 in Checkout wi...
by ozornick
5 hours ago
Version number stays un-u...
by trunky
Yesterday, 04:12 PM
Array to HTML "Table"
by HarmW94
Yesterday, 11:04 AM
shortcodes for ci4
by xsPurX
Yesterday, 09:29 AM
TypeError when trying to ...
by b126
Yesterday, 12:04 AM
Webhooks and WebSockets
by InsiteFX
04-18-2024, 10:39 AM
Retaining search variable...
by pchriley
04-18-2024, 05:46 AM

Forum Statistics
» Members: 84,658
» Latest member: oneseogg
» Forum threads: 77,564
» Forum posts: 375,913

Full Statistics

Search Forums

(Advanced Search)


Theme © iAndrew 2016 - Forum software by © MyBB