Plugin Directory

Changeset 1372567


Ignore:
Timestamp:
03/16/2016 07:21:27 PM (10 years ago)
Author:
jeanduez
Message:

correction

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uberkeen/trunk/uberkeen.php

    r1367092 r1372567  
    44Plugin URI: https://uberkeen.com
    55Description: Un plugin de communication live
    6 Version: 0.1
     6Version: 1.02
    77Author: Jean Duez
    88Author URI: https://uberkeen.com
     
    1515
    1616
    17 
    18 
    19 
    20 
    21 
    22 
    23 
    2417// Ajout du shortcode [uberkeen]
    2518add_shortcode('uberkeen','uberkeen_ub');
     
    3932        echo $mes_above;
    4033        echo " <br><button style='". $button_style ."' onclick='uberkeen_myFunction()'>". $mes_open ."</button>";
    41 
    4234        ?>
    4335
     
    4840        var myWindow;
    4941        function uberkeen_myFunction() {
    50             var myWindow = window.open('https://www.uberkeen.com/rtc/inter.php?client=<?php echo $maclef ?>','myWindow', 'width=400, height=400');
     42            var myWindow = window.open('https://www.uberkeen.com/rtc2/inter.php?client=<?php echo $maclef ?>','myWindow', 'width=800, height=400');
    5143        }
    5244        </script>
    5345
    5446        <?php
    55         ;
     47
    5648}
    5749   
     
    109101                        $wpdb->insert(
    110102                        $table_name,
    111                         array(
    112                         'clef' => $clef,
    113                         'button' => 'close',
    114                         'mes_above' => 'Click on this button to speak to us directly over the Internet. Make sure that your microphone is activated.',
    115                         'mes_open' => 'Talk to us',
    116                         'button_style' => 'background:white; cursor:hand; border:solid 1px black; font-class:verdana; font-weight:700; color: teal;',
    117                         )
     103                            array(
     104    'clef' => $clef,
     105    'button' => 'close',
     106    'mes_above' => 'Click on this button to speak to us directly over the Internet. Make sure that your microphone is activated.',
     107    'mes_open' => 'Talk to us',
     108    'button_style' => 'background:white; cursor:hand; border:solid 1px black; font-class:verdana; font-weight:700; color: teal;',
     109                            )
    118110                        );
    119                
    120 
    121             }
     111}
    122112
    123113
     
    130120    if($maclef == '' && $clef == '' ){
    131121        ?> 
    132          <p>&nbsp;</p>
     122
     123
    133124         <form method='post' action=''> <input type='text' name='clef' value='' placeholder="Your key"/>
    134125         <span class="submit"><input type="submit" class="button-primary" name="submit" value="register" />
     
    160151        dbDelta( $query );
    161152        }
    162         if (isset($_POST['close'])){
    163         global $wpdb;
    164         $table_name = $wpdb->prefix . 'uberkeen';
    165         $query="UPDATE $table_name SET button = 'close' " ;
    166         require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );
    167         dbDelta( $query );
    168         }
     153
    169154
    170155
     
    174159        $mes_open = $_POST['mes_open'];
    175160        $button_style = $_POST['button_style'];
     161
    176162                $wpdb->update(
    177                     $wpdb->prefix .'uberkeen',
     163                    $table_name = $wpdb->prefix . 'uberkeen',
     164                    //$wpdb->prefix .'uberkeen',
    178165                        array(
    179166                        'mes_above' => $mes_above,
     
    188175
    189176        }
    190    
    191 
    192177?>
    193178   
     
    204189
    205190
    206         <h2>UBERKEEN OPTIONS        </h2>
     191        <h2>UBERKEEN OPTIONS    222 </h2>
    207192        <p>&nbsp;</p>
    208193
    209194        <p><strong>Install your phone anywhere in your site by paste this tag: &nbsp;&nbsp; [uberkeen] &nbsp;&nbsp; and then you can open the line to listen your calls</strong>. <span class="submit"><br />
    210         Work with Chrome, Firefox, Opera. </span></p>
     195        Work with Chrome, Firefox, Opera. </span>       <br />
     196        <strong>Important: </strong>This app does not phone on fixed or cellular devices.
     197        It allows you to communicate on the web site.  You have to be online (open application in Uberkeen options) when someone call.</p>
     198        <p>&nbsp;</p>
     199
     200
     201
     202
     203
     204
    211205    <form method='post' action=''>
    212     <p class="submit"> <input type="submit" class="button-primary" name="open" id='open' value="open line"  onclick='uberkeen_myFunction()'/></p>   
     206    <p class="submit"> <input type="submit" class="button-primary" name="open" id='open' value="open line"  onclick='uberkeen_myFunction()'/>
     207    </p>   
    213208    </form>
    214209
    215     <p>&nbsp;</p>
     210        <script>
     211        var myWindow;
     212        function uberkeen_myFunction() {
     213<?php if (isset($maclef)) {echo "var myWindow = window.open('https://www.uberkeen.com/rtc2/inter.php?master=".$maclef."','myWindow', 'width=750, height=450');";} ?>           
     214        }
     215
     216        </script>
     217       
     218       
     219       
    216220
    217221
     
    234238    </table>
    235239    </form>
     240   
     241
     242
    236243      You can use html directly in the text above button and in the dedicaced field for the button itself.
    237244    <p>Example for text above button: &lt;h1&gt;This is a Blue Heading&lt;/h1&gt;      &lt;font color='FF00CC'&gt;here&lt;/font&gt;&lt;br&gt;
    238245    <p>Example for button: background:white; cursor:hand; border:solid 1px black; font-class:verdana; font-weight:700; color: teal;
    239 
    240 
    241    
    242    
    243         <script>
    244         var myWindow;
    245         function uberkeen_myFunction() {
    246 <?php if (isset($maclef)) {echo "var myWindow = window.open('https://www.uberkeen.com/rtc/inter.php?master=".$maclef."','myWindow', 'width=750, height=450');";} ?>         
    247         }
    248 
    249         </script>
    250         <?php
    251 
     246  <?php
    252247}
    253248// fin de page options
     
    276271}
    277272add_action('admin_menu', 'uberkeen_options_init');
    278 ?>
     273?>
     274     
     275   
Note: See TracChangeset for help on using the changeset viewer.