enabled mp cookie update
This commit is contained in:
parent
44017ffd35
commit
bf56f2e120
13
epub.php
13
epub.php
|
@ -98,7 +98,7 @@
|
||||||
$date = (new DateTime('today'))->format('Ymd');
|
$date = (new DateTime('today'))->format('Ymd');
|
||||||
|
|
||||||
// Socialter
|
// Socialter
|
||||||
if (isset($_POST['socialter']) && $_POST['socialter'])
|
/*if (isset($_POST['socialter']) && $_POST['socialter'])
|
||||||
{
|
{
|
||||||
// parameters hardcoded for now
|
// parameters hardcoded for now
|
||||||
$includeimages = false;
|
$includeimages = false;
|
||||||
|
@ -206,8 +206,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
write_epub($epub);
|
write_epub($epub);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
|
|
||||||
// Le Monde
|
// Le Monde
|
||||||
if (isset($_POST['lemonde']) && $_POST['lemonde'])
|
if (isset($_POST['lemonde']) && $_POST['lemonde'])
|
||||||
|
@ -325,8 +324,12 @@
|
||||||
{
|
{
|
||||||
if (isset($_POST['forcempcookies']) && $_POST['forcempcookies'])
|
if (isset($_POST['forcempcookies']) && $_POST['forcempcookies'])
|
||||||
{
|
{
|
||||||
|
$old = $mp_sessionid;
|
||||||
$mp_sessionid = get_mp_cookie();
|
$mp_sessionid = get_mp_cookie();
|
||||||
// todo save in settings
|
$settings = file_get_contents('settings.php');
|
||||||
|
$settings = str_replace($old, $mp_sessionid, $settings);
|
||||||
|
file_put_contents('settings.php', $settings);
|
||||||
|
echo '<div>Updated mpsessid in settings</div>';
|
||||||
}
|
}
|
||||||
|
|
||||||
$feedurl = 'https://www.mediapart.fr/articles/feed';
|
$feedurl = 'https://www.mediapart.fr/articles/feed';
|
||||||
|
@ -590,7 +593,7 @@
|
||||||
<input id="mediapart" name="mediapart" type="checkbox">
|
<input id="mediapart" name="mediapart" type="checkbox">
|
||||||
<label for="mediapart">From RSS</label>
|
<label for="mediapart">From RSS</label>
|
||||||
<br>
|
<br>
|
||||||
<input disabled id="forcempcookies" name="forcempcookies" type="checkbox">
|
<input id="forcempcookies" name="forcempcookies" type="checkbox">
|
||||||
<label for="forcempcookies">Force cookies</label>
|
<label for="forcempcookies">Force cookies</label>
|
||||||
|
|
||||||
<br><br>
|
<br><br>
|
||||||
|
|
Loading…
Reference in New Issue