Ver Mensaje Individual
  #3 (permalink)  
Antiguo 11/10/2017, 09:15
pithon
 
Fecha de Ingreso: mayo-2011
Mensajes: 1.201
Antigüedad: 13 años
Puntos: 10
Respuesta: opciones para realizar una interfaz

Estoy probando imap pero sigo teniendo errores intento saber la codificacion que tengo que hacer para mostrar los mensajes uso fetchstructure para saberlo algo asi:

Código PHP:
Ver original
  1. $info = imap_fetchstructure($cn,5);
  2.  
  3. //muestro el valor de encoding
  4.  
  5. echo $info->encoding;
  6.  
  7. //no me muestra nada
  8.  
  9. print_r($info);
  10.  
  11. /*
  12. stdClass Object
  13. (
  14.     [type] => 1
  15.     [encoding] => 0
  16.     [ifsubtype] => 1
  17.     [subtype] => ALTERNATIVE
  18.     [ifdescription] => 0
  19.     [ifid] => 0
  20.     [ifdisposition] => 0
  21.     [ifdparameters] => 0
  22.     [ifparameters] => 1
  23.     [parameters] => Array
  24.         (
  25.             [0] => stdClass Object
  26.                 (
  27.                     [attribute] => boundary
  28.                     [value] => 089e08245e1837a2010553e0feb5
  29.                 )
  30.  
  31.         )
  32.  
  33.     [parts] => Array
  34.         (
  35.             [0] => stdClass Object
  36.                 (
  37.                     [type] => 0
  38.                     [encoding] => 0
  39.                     [ifsubtype] => 1
  40.                     [subtype] => PLAIN
  41.                     [ifdescription] => 0
  42.                     [ifid] => 0
  43.                     [lines] => 1
  44.                     [bytes] => 10
  45.                     [ifdisposition] => 0
  46.                     [ifdparameters] => 0
  47.                     [ifparameters] => 1
  48.                     [parameters] => Array
  49.                         (
  50.                             [0] => stdClass Object
  51.                                 (
  52.                                     [attribute] => charset
  53.                                     [value] => UTF-8
  54.                                 )
  55.  
  56.                         )
  57.  
  58.                 )
  59.  
  60.             [1] => stdClass Object
  61.                 (
  62.                     [type] => 0
  63.                     [encoding] => 0
  64.                     [ifsubtype] => 1
  65.                     [subtype] => HTML
  66.                     [ifdescription] => 0
  67.                     [ifid] => 0
  68.                     [lines] => 1
  69.                     [bytes] => 32
  70.                     [ifdisposition] => 0
  71.                     [ifdparameters] => 0
  72.                     [ifparameters] => 1
  73.                     [parameters] => Array
  74.                         (
  75.                             [0] => stdClass Object
  76.                                 (
  77.                                     [attribute] => charset
  78.                                     [value] => UTF-8
  79.                                 )
  80.  
  81.                         )
  82.  
  83.                 )
  84.  
  85.         )
  86.  
  87. )
  88.  
  89. */

que puede estar pasando quiero mostrar el mensaje luego con imap_fetchbody dependiendo del resultado que me de pero no entiendo porque no me muestra nada en pantalla o que estoy haciendo mal.