xoops forums

Forum Index


Board index » All Posts (baloch)




baloch

Just popping in
Posted on: 2009/8/24 10:06
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#1

Re: Problem with xoopspoll module

There is no option in poll preferences to restrict anonymous for voting. there is something to do with xoopspolllog.php function to restrict anonymous so not understanding it how can i restrict them


baloch

Just popping in
Posted on: 2009/8/24 8:44
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#2

Re: Problem with xoopspoll module

It is allowing anynoums to vote sorry for mistake i disabled only anymous comments not vote. how can i restirct anonymous votes?


baloch

Just popping in
Posted on: 2009/8/24 8:34
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#3

Re: Problem with xoopspoll module

I restricted anonymous voting also but still it is doing the same?
i looked at the other thread which you pointed out now. but can we modify the functon to further tighten the voting?


baloch

Just popping in
Posted on: 2009/8/24 6:39
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#4

Problem with xoopspoll module

I am using xoopspoll in my one site. I see someone spamming the poll with bogus votes. I even enabled restriction to user level and ip level. But still i saw yesterday in one hour someone posted 700 votes. wondering How it is possible?


baloch

Just popping in
Posted on: 2009/6/25 23:41
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#5

Re: how can i create and use xoops object handler in my module?

Hi Trabis sorry to worry u again i tried the method u shown above to retrieve data from database but i am getting this error
atal error: Call to a member function getVars() on a non-object in C:\xampp\htdocs

here is my class
<?php
if (!defined("XOOPS_ROOT_PATH")) {
    die(
"XOOPS root path not defined");


//create the xoopsobject for crud opeation
class AudioAudio extends XoopsObject

    function 
AudioAudio()
    {
    
        
$this->__construct();
    
    }
    
    function 
__construct()
    {
        
$this->initVar("id"XOBJ_DTYPE_INT);
        
$this->initVar("source"XOBJ_DTYPE_TXTBOX);
        
$this->initVar("title"XOBJ_DTYPE_TXTBOX);
        
$this->initVar("download"XOBJ_DTYPE_TXTBOX);
        
$this->initVar("size"XOBJ_DTYPE_TXTBOX);
        
$this->initVar("type"XOBJ_DTYPE_TXTBOX);
        
$this->initVar("date"XOBJ_DTYPE_TXTBOX);
    }
}

class 
AudioAudioHandler extends XoopsPersistableObjectHandler
{
    function 
AudioAudioHandler(&$db)
    {
        
$this->__construct($db);
    }

    function 
__construct(&$db)
    {
        
parent::__construct($db'audios''AudioAudio''id');
    }
    
    

}
?>


here i am trying to retireve
$obj_handler =& xoops_getModuleHandler('audio','audio');
$obj $obj_handler->getAll($criteria null$fields null$asObject true$id_as_key true); 
echo 
"<tr class='odd'><td>".$obj->getVars("source")."</td>
    <td>"
.$obj->getVars("title")."</td>
    <td>"
.$obj->getVars("type")."</td>
    <td>"
.$obj->getVars("date")."</td>";



in a debug it shows select * from audios but it i canot list the data due to the error above


baloch

Just popping in
Posted on: 2009/6/25 12:50
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#6

Re: how can i create and use xoops object handler in my module?

Thanks Trabis for your easy explanation. Trabis The Xoops's Future...


baloch

Just popping in
Posted on: 2009/6/24 14:41
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#7

Re: how can i create and use xoops object handler in my module?

ok thanks a lot understood the object handler, about criteria still confused. is critirea about setting like where clause, limit, orderby, groupy etc or something else?


baloch

Just popping in
Posted on: 2009/6/24 12:37
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#8

Re: how can i create and use xoops object handler in my module?

I went through Faq module by catzwolf it is using normal quries. I am trying to understand and if anyone here to explain me how to extend xoopsobjecthandler class to create module_handler. or may be i am not understanding how to explain properly.


baloch

Just popping in
Posted on: 2009/6/24 8:12
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#9

how can i create and use xoops object handler in my module?

I am developing a module i want to use XOOPS Object handler for creating and updating the records in database. But can please any one explain to me how the objecthandler (module_handler) class works?? How can i extend the class?



baloch

Just popping in
Posted on: 2009/6/21 9:01
baloch
baloch (Show more)
Just popping in
Posts: 34
Since: 2006/3/22
#10

Re: HI i am trying to assign data to template but it giving me error please help

How do i use assign template in admin section?



TopTop
(1) 2 3 »