title: Call function in ASP.NET Master Page (.Master) from aspx.cs
body: <p>In the ASP.NET Master Page (.Master) there is a text-box that should filter the content in a website. To do it I would like to call the function GetMessageLogs in the .aspx.cs file. </p>
  
  <blockquote>
    <p>Site.Master:</p>
  </blockquote>
  
  <pre><code>&lt;button onclick="containCatText()" class="catbtn"&gt;Category&lt;/button&gt;
      &lt;div id="myDropdownCat" class="catdown-content"&gt;
          &lt;input type="text" placeholder="Search.." id="myCat" onkeyup="filterFunction()"&gt;
      &lt;/div&gt;
      &lt;script&gt;
          var myCat = document.getElementById("myCat").value;
      &lt;/script&gt;
  </code></pre>
  
  <blockquote>
    <p>Feeds.aspx:</p>
  </blockquote>
  
  <pre><code>&lt;%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Feeds.aspx.cs" Inherits="ReportTool.Users.Feeds" %&gt;
  </code></pre>
  
  <blockquote>
    <p>Feeds.aspx.cs:</p>
  </blockquote>
  
  <pre><code>namespace ReportTool.Users
  {
      public partial class Feeds : System.Web.UI.Page
      {
          Inov.ReportTool rt = new Inov.ReportTool();    
          MessageLogs = rt.GetMessageLogs(null, Server.MapPath("/ReportTool/Photo") + "\\", Server.MapPath("/ReportTool/Video") + "\\", new DateTime(2016, 09, 15),DateTime.Now, "%J%","Tr");
  </code></pre>
  
  <p>My question is simply how do I replace the "%J%" in the Feeds.aspx.cs from the variable myCat from Site.Maste?</p>